From c7c95177297e4643b92cfa2329d76c197768062f Mon Sep 17 00:00:00 2001 From: OpenUI5 Bot Date: Wed, 6 May 2026 21:11:46 +0200 Subject: [PATCH 1/5] =?UTF-8?q?=F0=9F=A4=96=20Merge=20PR=20#74931=20[openu?= =?UTF-8?q?i5]=20Remove=20type=20definitions=20for=20deleted=20sap.ui.webc?= =?UTF-8?q?.*=20libraries=20by=20@openui5bot?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Florian Vogt --- types/openui5/index.d.ts | 3 - types/openui5/openui5-tests.ts | 2 + types/openui5/package.json | 2 +- types/openui5/sap.ui.webc.common.d.ts | 164 - types/openui5/sap.ui.webc.fiori.d.ts | 16235 -------- types/openui5/sap.ui.webc.main.d.ts | 51365 ------------------------ 6 files changed, 3 insertions(+), 67768 deletions(-) delete mode 100644 types/openui5/sap.ui.webc.common.d.ts delete mode 100644 types/openui5/sap.ui.webc.fiori.d.ts delete mode 100644 types/openui5/sap.ui.webc.main.d.ts diff --git a/types/openui5/index.d.ts b/types/openui5/index.d.ts index 33df30be9bc2fb..480f42880a9ffa 100644 --- a/types/openui5/index.d.ts +++ b/types/openui5/index.d.ts @@ -31,7 +31,4 @@ /// /// /// -/// -/// -/// /// diff --git a/types/openui5/openui5-tests.ts b/types/openui5/openui5-tests.ts index 7fe28439bd5100..c2838f57eef723 100644 --- a/types/openui5/openui5-tests.ts +++ b/types/openui5/openui5-tests.ts @@ -294,3 +294,5 @@ const p13nEngine = new Engine(); // version 1.146.0 added - tests are not required as the type definitions are generated and the generator is sufficiently tested // version 1.147.0 added - tests are not required as the type definitions are generated and the generator is sufficiently tested + +// sap.ui.webc.* libraries removed - tests are not required as the type definitions are generated and the generator is sufficiently tested diff --git a/types/openui5/package.json b/types/openui5/package.json index fc87e913b89c40..11e1fa09417eb5 100644 --- a/types/openui5/package.json +++ b/types/openui5/package.json @@ -5,7 +5,7 @@ "nonNpm": true, "nonNpmDescription": "openui5", "projects": [ - "https://github.com/SAP/openui5" + "https://github.com/UI5/openui5" ], "minimumTypeScriptVersion": "5.0", "dependencies": { diff --git a/types/openui5/sap.ui.webc.common.d.ts b/types/openui5/sap.ui.webc.common.d.ts deleted file mode 100644 index d9b6564c53258d..00000000000000 --- a/types/openui5/sap.ui.webc.common.d.ts +++ /dev/null @@ -1,164 +0,0 @@ -// For Library Version: 1.146.0 - -declare module "sap/ui/webc/common/library" {} - -declare module "sap/ui/webc/common/WebComponent" { - import { - default as WebComponent1, - MetadataOptions as MetadataOptions1, - $WebComponentSettings as $WebComponentSettings1, - } from "sap/ui/core/webc/WebComponent"; - - import WebComponentMetadata from "sap/ui/webc/common/WebComponentMetadata"; - - /** - * Base Class for Web Components. Web Components are agnostic UI elements which can be integrated into the - * UI5 programming model by using this wrapper control. This wrapper control takes care to propagate the - * properties, the aggregations and the events. It also ensures to render the control and put the aggregated - * controls in the dedicated slots of the Web Component. - * - * @since 1.92.0 - * @deprecated As of version 1.118.0. Use sap.ui.core.webc.WebComponent instead! - * @experimental As of version 1.92.0. The API might change. It is not intended for productive usage yet! - */ - export default class WebComponent extends WebComponent1 { - /** - * Constructs and initializes a Web Component Wrapper with the given `sId` and settings. - */ - constructor( - /** - * Object with initial settings for the new control - */ - mSettings?: $WebComponentSettings - ); - /** - * Constructs and initializes a Web Component Wrapper with the given `sId` and settings. - */ - constructor( - /** - * Optional ID for the new control; generated automatically if no non-empty ID is given Note: this can be - * omitted, no matter whether `mSettings` will be given or not! - */ - sId?: string, - /** - * Object with initial settings for the new control - */ - mSettings?: $WebComponentSettings - ); - - /** - * Defines a new subclass of WebComponent with the name `sClassName` and enriches it with the information - * contained in `oClassInfo`. - * - * `oClassInfo` can contain the same information that {@link sap.ui.base.ManagedObject.extend} already accepts, - * plus the `dnd` property in the metadata object literal to configure drag-and-drop behavior (see {@link sap.ui.core.webc.WebComponent.MetadataOptions MetadataOptions } - * for details). Objects describing aggregations can also have a `dnd` property when used for a class extending - * `WebComponent` (see {@link sap.ui.base.ManagedObject.MetadataOptions.AggregationDnD AggregationDnD}). - * - * Example: - * ```javascript - * - * WebComponent.extend('sap.mylib.MyElement', { - * metadata : { - * library : 'sap.mylib', - * tag : 'my-webcomponent', - * properties : { - * value : 'string', - * width : { - * type: 'sap.ui.core.CSSSize', - * mapping: 'style' - * } - * }, - * defaultAggregation: "content", - * aggregations : { - * content : { - * type: 'sap.ui.core.Control', - * multiple : true - * }, - * header : { - * type : 'sap.ui.core.Control', - * multiple : false, - * slot: 'header' - * } - * } - * } - * }); - * ``` - * - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class to be created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object. If not given, it defaults to `sap.ui.core.ElementMetadata`. - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.common.WebComponent. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - } - /** - * The structure of the "metadata" object which is passed when inheriting from sap.ui.core.Element using - * its static "extend" method. See {@link sap.ui.core.Element.extend} for details on its usage. - * - * @deprecated As of version 1.118.0. because it is part of the deprecated package sap.ui.webc.common.WebComponent - */ - export type MetadataOptions = MetadataOptions1; - - /** - * Describes the settings that can be provided to the WebComponent constructor. - * - * @deprecated As of version 1.118.0. Use sap.ui.core.webc.WebComponent instead! - * @experimental As of version 1.92.0. The API might change. It is not intended for productive usage yet! - */ - export interface $WebComponentSettings extends $WebComponentSettings1 {} -} - -declare module "sap/ui/webc/common/WebComponentMetadata" { - import WebComponentMetadata1 from "sap/ui/core/webc/WebComponentMetadata"; - - /** - * @since 1.92.0 - * @deprecated As of version 1.118.0. Use sap.ui.core.webc.WebComponentMetadata instead! - * @experimental As of version 1.92.0. The API might change. It is not intended for productive usage yet! - */ - export default class WebComponentMetadata extends WebComponentMetadata1 { - /** - * Creates a new metadata object for a WebComponent Wrapper subclass. - */ - constructor( - /** - * fully qualified name of the class that is described by this metadata object - */ - sClassName: string, - /** - * static info to construct the metadata from - */ - oClassInfo: object - ); - } -} - -declare namespace sap { - interface IUI5DefineDependencyNames { - "sap/ui/webc/common/library": undefined; - - "sap/ui/webc/common/WebComponent": undefined; - - "sap/ui/webc/common/WebComponentMetadata": undefined; - } -} diff --git a/types/openui5/sap.ui.webc.fiori.d.ts b/types/openui5/sap.ui.webc.fiori.d.ts deleted file mode 100644 index dcec62d5320d59..00000000000000 --- a/types/openui5/sap.ui.webc.fiori.d.ts +++ /dev/null @@ -1,16235 +0,0 @@ -// For Library Version: 1.146.0 - -declare module "sap/ui/webc/fiori/library" { - /** - * Different types of Bar design - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'BarDesign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum BarDesign { - /** - * Floating Footer type - there is visible border on all sides - */ - FloatingFooter = "FloatingFooter", - /** - * Footer type - */ - Footer = "Footer", - /** - * Default type - */ - Header = "Header", - /** - * Subheader type - */ - Subheader = "Subheader", - } - /** - * Different types of FCLLayout. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'FCLLayout'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum FCLLayout { - /** - * Desktop: -- -- 100 only the End column is displayed Tablet: -- -- 100 only the End column is displayed - * Phone: -- -- 100 only the End column is displayed - * - * Use to display a detail-detail page only, when the user should focus entirely on it. - */ - EndColumnFullScreen = "EndColumnFullScreen", - /** - * Desktop: -- 100 -- only the Mid column is displayed Tablet: -- 100 -- only the Mid column is displayed - * Phone: -- 100 -- only the Mid column is displayed - * - * Use to display a detail page only, when the user should focus entirely on it. - */ - MidColumnFullScreen = "MidColumnFullScreen", - /** - * The layout will display 1 column. - */ - OneColumn = "OneColumn", - /** - * Desktop: 25 - 25 - 50 Start, Mid and End (expanded) columns are displayed Tablet: 0 - 33 - 67 Mid and - * End (expanded) columns are displayed, Start is accessible by layout arrows Phone: -- -- 100 (only the - * End column is displayed) - * - * Use to display all three pages (list, detail, detail-detail) when the user should focus on the detail-detail. - */ - ThreeColumnsEndExpanded = "ThreeColumnsEndExpanded", - /** - * Desktop: 25 - 50 - 25 Start, Mid (expanded) and End columns are displayed Tablet: 0 - 67 - 33 Mid (expanded) - * and End columns are displayed, Start is accessible by a layout arrow Phone: -- -- 100 only the End column - * is displayed - * - * Use to display all three pages (list, detail, detail-detail) when the user should focus on the detail. - */ - ThreeColumnsMidExpanded = "ThreeColumnsMidExpanded", - /** - * Desktop: 33 - 67 - 0 Start and Mid (expanded) columns are displayed, End is accessible by a layout arrow - * Tablet: 33 - 67 - 0 Start and Mid (expanded) columns are displayed, End is accessible by a layout arrow - * Phone: -- -- 100 only the End column is displayed - * - * Use to display the list and detail pages when the user should focus on the detail. The detail-detail - * is still loaded and easily accessible with a layout arrow. - */ - ThreeColumnsMidExpandedEndHidden = "ThreeColumnsMidExpandedEndHidden", - /** - * Desktop: 67 - 33 - 0 Start (expanded) and Mid columns are displayed, End is accessible by layout arrows - * Tablet: 67 - 33 - 0 Start (expanded) and Mid columns are displayed, End is accessible by layout arrows - * Phone: -- -- 100 only the End column is displayed - * - * Use to display the list and detail pages when the user should focus on the list. The detail-detail is - * still loaded and easily accessible with layout arrows. - */ - ThreeColumnsStartExpandedEndHidden = "ThreeColumnsStartExpandedEndHidden", - /** - * Desktop: 33 - 67 - -- Start and Mid (expanded) columns are displayed Tablet: 33 - 67 - -- Start and Mid - * (expanded) columns are displayed Phone: -- 100 -- only the Mid column is displayed - * - * Use to display both a list and a detail page when the user should focus on the detail page. - */ - TwoColumnsMidExpanded = "TwoColumnsMidExpanded", - /** - * Desktop: 67 - 33 - -- Start (expanded) and Mid columns are displayed Tablet: 67 - 33 - -- Start (expanded) - * and Mid columns are displayed Phone: -- 100 -- only the Mid column is displayed - * - * Use to display both a list and a detail page when the user should focus on the list page. - */ - TwoColumnsStartExpanded = "TwoColumnsStartExpanded", - } - /** - * Interface for components that may be slotted inside `ui5-page` as header and footer. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export interface IBar { - __implements__sap_ui_webc_fiori_IBar: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-view-settings-dialog` as filter items - * - * @since 1.97.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.97.0. This API is experimental and might change significantly. - */ - export interface IFilterItem { - __implements__sap_ui_webc_fiori_IFilterItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-filter-item` as values - * - * @since 1.97.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.97.0. This API is experimental and might change significantly. - */ - export interface IFilterItemOption { - __implements__sap_ui_webc_fiori_IFilterItemOption: boolean; - } - - /** - * Different types of IllustrationMessageSize. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'IllustrationMessageSize'. - * - * @since 1.106.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.106.0. This API is experimental and might change significantly. - */ - export enum IllustrationMessageSize { - /** - * Automatically decides the `Illustration` size (`Base`, `Spot`, `Dialog`, or `Scene`) depending on the - * `IllustratedMessage` container width. - * - * **Note:** `Auto` is the only option where the illustration size is changed according to the available - * container width. If any other `IllustratedMessageSize` is chosen, it remains until changed by the app - * developer. - */ - Auto = "Auto", - /** - * Base `Illustration` size (XS breakpoint). Suitable for cards (two columns). - * - * **Note:** When `Base` is in use, no illustration is displayed. - */ - Base = "Base", - /** - * Dialog `Illustration` size (M breakpoint). Suitable for dialogs. - */ - Dialog = "Dialog", - /** - * Scene `Illustration` size (L breakpoint). Suitable for a `Page` or a table. - */ - Scene = "Scene", - /** - * Spot `Illustration` size (S breakpoint). Suitable for cards (four columns). - */ - Spot = "Spot", - } - /** - * Different illustration types of Illustrated Message. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'IllustrationMessageType'. - * - * @since 1.95.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.95.0. This API is experimental and might change significantly. - */ - export enum IllustrationMessageType { - /** - * "Add Column" illustration type. - */ - AddColumn = "AddColumn", - /** - * "Add Dimensions" illustration type. - */ - AddDimensions = "AddDimensions", - /** - * "Add People" illustration type. - */ - AddPeople = "AddPeople", - /** - * "Balloon Sky" illustration type. - */ - BalloonSky = "BalloonSky", - /** - * "Before Search" illustration type. - */ - BeforeSearch = "BeforeSearch", - /** - * "Connection" illustration type. - */ - Connection = "Connection", - /** - * "Empty Calendar" illustration type. - */ - EmptyCalendar = "EmptyCalendar", - /** - * "Empty List" illustration type. - */ - EmptyList = "EmptyList", - /** - * "Empty Planning Calendar" illustration type. - */ - EmptyPlanningCalendar = "EmptyPlanningCalendar", - /** - * "Error Screen" illustration type. - */ - ErrorScreen = "ErrorScreen", - /** - * "Filter Table" illustration type. - */ - FilterTable = "FilterTable", - /** - * "Group Table" illustration type. - */ - GroupTable = "GroupTable", - /** - * "No Activities" illustration type. - */ - NoActivities = "NoActivities", - /** - * "No Columns Set" illustration type. - */ - NoColumnsSet = "NoColumnsSet", - /** - * "No Data" illustration type. - */ - NoData = "NoData", - /** - * "No Dimensions Set" illustration type. - */ - NoDimensionsSet = "NoDimensionsSet", - /** - * "No Entries" illustration type. - */ - NoEntries = "NoEntries", - /** - * "No Filter Results" illustration type. - */ - NoFilterResults = "NoFilterResults", - /** - * "No Email" illustration type. - */ - NoMail = "NoMail", - /** - * "No Email v1" illustration type. - */ - NoMail_v1 = "NoMail_v1", - /** - * "No Notifications" illustration type. - */ - NoNotifications = "NoNotifications", - /** - * "No Saved Items" illustration type. - */ - NoSavedItems = "NoSavedItems", - /** - * "No Saved Items v1" illustration type. - */ - NoSavedItems_v1 = "NoSavedItems_v1", - /** - * "No Search Results" illustration type. - */ - NoSearchResults = "NoSearchResults", - /** - * "No Tasks" illustration type. - */ - NoTasks = "NoTasks", - /** - * "No Tasks v1" illustration type. - */ - NoTasks_v1 = "NoTasks_v1", - /** - * "Page Not Found" illustration type. - */ - PageNotFound = "PageNotFound", - /** - * "Reload Screen" illustration type. - */ - ReloadScreen = "ReloadScreen", - /** - * "Resize Column" illustration type. - */ - ResizeColumn = "ResizeColumn", - /** - * "Search Earth" illustration type. - */ - SearchEarth = "SearchEarth", - /** - * "Search Folder" illustration type. - */ - SearchFolder = "SearchFolder", - /** - * "Simple Balloon" illustration type. - */ - SimpleBalloon = "SimpleBalloon", - /** - * "Simple Bell" illustration type. - */ - SimpleBell = "SimpleBell", - /** - * "Simple Calendar" illustration type. - */ - SimpleCalendar = "SimpleCalendar", - /** - * "Simple CheckMark" illustration type. - */ - SimpleCheckMark = "SimpleCheckMark", - /** - * "Simple Connection" illustration type. - */ - SimpleConnection = "SimpleConnection", - /** - * "Simple Empty Doc" illustration type. - */ - SimpleEmptyDoc = "SimpleEmptyDoc", - /** - * "Simple Empty List" illustration type. - */ - SimpleEmptyList = "SimpleEmptyList", - /** - * "Simple Error" illustration type. - */ - SimpleError = "SimpleError", - /** - * "Simple Magnifier" illustration type. - */ - SimpleMagnifier = "SimpleMagnifier", - /** - * "Simple Mail" illustration type. - */ - SimpleMail = "SimpleMail", - /** - * "Simple No Saved Items" illustration type. - */ - SimpleNoSavedItems = "SimpleNoSavedItems", - /** - * "Simple Not Found Magnifier" illustration type. - */ - SimpleNotFoundMagnifier = "SimpleNotFoundMagnifier", - /** - * "Simple Reload" illustration type. - */ - SimpleReload = "SimpleReload", - /** - * "Simple Task" illustration type. - */ - SimpleTask = "SimpleTask", - /** - * "Sleeping Bell" illustration type. - */ - SleepingBell = "SleepingBell", - /** - * "Sort Column" illustration type. - */ - SortColumn = "SortColumn", - /** - * "Success Balloon" illustration type. - */ - SuccessBalloon = "SuccessBalloon", - /** - * "Success CheckMark" illustration type. - */ - SuccessCheckMark = "SuccessCheckMark", - /** - * "Success HighFive" illustration type. - */ - SuccessHighFive = "SuccessHighFive", - /** - * "Success Screen" illustration type. - */ - SuccessScreen = "SuccessScreen", - /** - * "Survey" illustration type. - */ - Survey = "Survey", - /** - * "Tent" illustration type. - */ - Tent = "Tent", - /** - * "TntChartArea" illustration type. - */ - TntChartArea = "TntChartArea", - /** - * "TntChartArea2" illustration type. - */ - TntChartArea2 = "TntChartArea2", - /** - * "TntChartBar" illustration type. - */ - TntChartBar = "TntChartBar", - /** - * "TntChartBPMNFlow" illustration type. - */ - TntChartBPMNFlow = "TntChartBPMNFlow", - /** - * "TntChartBullet" illustration type. - */ - TntChartBullet = "TntChartBullet", - /** - * "TntChartDoughnut" illustration type. - */ - TntChartDoughnut = "TntChartDoughnut", - /** - * "TntChartFlow" illustration type. - */ - TntChartFlow = "TntChartFlow", - /** - * "TntChartGantt" illustration type. - */ - TntChartGantt = "TntChartGantt", - /** - * "TntChartOrg" illustration type. - */ - TntChartOrg = "TntChartOrg", - /** - * "TntChartPie" illustration type. - */ - TntChartPie = "TntChartPie", - /** - * "TntCodePlaceholder" illustration type. - */ - TntCodePlaceholder = "TntCodePlaceholder", - /** - * "TntCompany" illustration type. - */ - TntCompany = "TntCompany", - /** - * "TntComponents" illustration type. - */ - TntComponents = "TntComponents", - /** - * "TntExternalLink" illustration type. - */ - TntExternalLink = "TntExternalLink", - /** - * "TntFaceID" illustration type. - */ - TntFaceID = "TntFaceID", - /** - * "TntFingerprint" illustration type. - */ - TntFingerprint = "TntFingerprint", - /** - * "TntLock" illustration type. - */ - TntLock = "TntLock", - /** - * "TntMission" illustration type. - */ - TntMission = "TntMission", - /** - * "TntNoApplications" illustration type. - */ - TntNoApplications = "TntNoApplications", - /** - * "TntNoFlows" illustration type. - */ - TntNoFlows = "TntNoFlows", - /** - * "TntNoUsers" illustration type. - */ - TntNoUsers = "TntNoUsers", - /** - * "TntRadar" illustration type. - */ - TntRadar = "TntRadar", - /** - * "TntSecrets" illustration type. - */ - TntSecrets = "TntSecrets", - /** - * "TntServices" illustration type. - */ - TntServices = "TntServices", - /** - * "TntSessionExpired" illustration type. - */ - TntSessionExpired = "TntSessionExpired", - /** - * "TntSessionExpiring" illustration type. - */ - TntSessionExpiring = "TntSessionExpiring", - /** - * "TntSuccess" illustration type. - */ - TntSuccess = "TntSuccess", - /** - * "TntSuccessfulAuth" illustration type. - */ - TntSuccessfulAuth = "TntSuccessfulAuth", - /** - * "TntSystems" illustration type. - */ - TntSystems = "TntSystems", - /** - * "TntTeams" illustration type. - */ - TntTeams = "TntTeams", - /** - * "TntTools" illustration type. - */ - TntTools = "TntTools", - /** - * "TntUnableToLoad" illustration type. - */ - TntUnableToLoad = "TntUnableToLoad", - /** - * "TntUnlock" illustration type. - */ - TntUnlock = "TntUnlock", - /** - * "TntUnsuccessfulAuth" illustration type. - */ - TntUnsuccessfulAuth = "TntUnsuccessfulAuth", - /** - * "TntUser2" illustration type. - */ - TntUser2 = "TntUser2", - /** - * "Unable To Load" illustration type. - */ - UnableToLoad = "UnableToLoad", - /** - * "Unable To Load Image" illustration type. - */ - UnableToLoadImage = "UnableToLoadImage", - /** - * "Unable To Upload" illustration type. - */ - UnableToUpload = "UnableToUpload", - /** - * "Upload Collection" illustration type. - */ - UploadCollection = "UploadCollection", - /** - * "Upload To Cloud" illustration type. - */ - UploadToCloud = "UploadToCloud", - } - /** - * Interface for components that can be slotted inside `ui5-media-gallery` as items. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export interface IMediaGalleryItem { - __implements__sap_ui_webc_fiori_IMediaGalleryItem: boolean; - } - - /** - * Interface for components that may be slotted as an action inside `ui5-li-notification` and `ui5-li-notification-group` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface INotificationAction { - __implements__sap_ui_webc_fiori_INotificationAction: boolean; - } - - /** - * Interface for components that may be slotted inside a notification list - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface INotificationListItem { - __implements__sap_ui_webc_fiori_INotificationListItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-product-switch` as items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IProductSwitchItem { - __implements__sap_ui_webc_fiori_IProductSwitchItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-shellbar` as items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IShellBarItem { - __implements__sap_ui_webc_fiori_IShellBarItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-side-navigation` as items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ISideNavigationItem { - __implements__sap_ui_webc_fiori_ISideNavigationItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-side-navigation-item` as sub-items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ISideNavigationSubItem { - __implements__sap_ui_webc_fiori_ISideNavigationSubItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-view-settings-dialog` as sort items - * - * @since 1.97.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.97.0. This API is experimental and might change significantly. - */ - export interface ISortItem { - __implements__sap_ui_webc_fiori_ISortItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-timeline` as items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ITimelineItem { - __implements__sap_ui_webc_fiori_ITimelineItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-upload-collection` as items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IUploadCollectionItem { - __implements__sap_ui_webc_fiori_IUploadCollectionItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-wizard` as wizard steps - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IWizardStep { - __implements__sap_ui_webc_fiori_IWizardStep: boolean; - } - - /** - * Defines the layout of the content displayed in the `ui5-media-gallery-item`. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'MediaGalleryItemLayout'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum MediaGalleryItemLayout { - /** - * Recommended to use when the item contains an image. - * When a thumbnail is selected, it makes the corresponding enlarged content appear in a square display - * area. - */ - Square = "Square", - /** - * Recommended to use when the item contains video content. - * When a thumbnail is selected, it makes the corresponding enlarged content appear in a wide display area - * (stretched to fill all of the available width) for optimal user experiance. - */ - Wide = "Wide", - } - /** - * Defines the layout type of the thumbnails list of the `ui5-media-gallery` component. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'MediaGalleryLayout'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum MediaGalleryLayout { - /** - * The layout is determined automatically. - */ - Auto = "Auto", - /** - * Displays the layout as a horizontal split between the thumbnails list and the selected image. - */ - Horizontal = "Horizontal", - /** - * Displays the layout as a vertical split between the thumbnails list and the selected image. - */ - Vertical = "Vertical", - } - /** - * Defines the horizontal alignment of the thumbnails menu of the `ui5-media-gallery` component. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'MediaGalleryMenuHorizontalAlign'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum MediaGalleryMenuHorizontalAlign { - /** - * Displays the menu on the left side of the target. - */ - Left = "Left", - /** - * Displays the menu on the right side of the target. - */ - Right = "Right", - } - /** - * Types for the vertical alignment of the thumbnails menu of the `ui5-media-gallery` component. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'MediaGalleryMenuVerticalAlign'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum MediaGalleryMenuVerticalAlign { - /** - * Displays the menu at the bottom of the reference control. - */ - Bottom = "Bottom", - /** - * Displays the menu at the top of the reference control. - */ - Top = "Top", - } - /** - * Available Page Background Design. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'PageBackgroundDesign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum PageBackgroundDesign { - /** - * Page background color when a List is set as the Page content. - */ - List = "List", - /** - * A solid background color dependent on the theme. - */ - Solid = "Solid", - /** - * Transparent background for the page. - */ - Transparent = "Transparent", - } - /** - * SideContent FallDown options. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'SideContentFallDown'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum SideContentFallDown { - /** - * Side content falls down on breakpoints below L - */ - BelowL = "BelowL", - /** - * Side content falls down on breakpoints below M - */ - BelowM = "BelowM", - /** - * Side content falls down on breakpoints below XL - */ - BelowXL = "BelowXL", - /** - * Side content falls down on breakpoint M and the minimum width for the side content - */ - OnMinimumWidth = "OnMinimumWidth", - } - /** - * Side Content position options. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'SideContentPosition'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum SideContentPosition { - /** - * The side content is on the right side of the main container in left-to-right mode and on the left side - * in right-to-left mode. - */ - End = "End", - /** - * The side content is on the left side of the main container in left-to-right mode and on the right side - * in right-to-left mode. - */ - Start = "Start", - } - /** - * Side Content visibility options. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'SideContentVisibility'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum SideContentVisibility { - /** - * Show the side content on any breakpoint - */ - AlwaysShow = "AlwaysShow", - /** - * Don't show the side content on any breakpoints - */ - NeverShow = "NeverShow", - /** - * Show the side content on XL breakpoint - */ - ShowAboveL = "ShowAboveL", - /** - * Show the side content on L and XL breakpoints - */ - ShowAboveM = "ShowAboveM", - /** - * Show the side content on M, L and XL breakpoints - */ - ShowAboveS = "ShowAboveS", - } - /** - * Available Timeline layout orientation - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'TimelineLayout'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum TimelineLayout { - /** - * Horizontal layout - */ - Horizontal = "Horizontal", - /** - * Vertical layout Default type - */ - Vertical = "Vertical", - } - /** - * Different types of UploadState. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'UploadState'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum UploadState { - /** - * The file has been uploaded successfully. - */ - Complete = "Complete", - /** - * The file cannot be uploaded due to an error. - */ - Error = "Error", - /** - * The file is awaiting an explicit command to start being uploaded. - */ - Ready = "Ready", - /** - * The file is currently being uploaded. - */ - Uploading = "Uploading", - } - /** - * Different types of Bar. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'ViewSettingsDialogMode'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum ViewSettingsDialogMode { - /** - * Filter type - */ - Filter = "Filter", - /** - * Default type - */ - Sort = "Sort", - } - /** - * Enumeration for different content layouts of the `ui5-wizard`. - * - * This enum is part of the 'sap/ui/webc/fiori/library' module export and must be accessed by the property - * 'WizardContentLayout'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.fiori - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum WizardContentLayout { - /** - * Display the content of the `ui5-wizard` as multiple steps in a scroll section. - */ - MultipleSteps = "MultipleSteps", - /** - * Display the content of the `ui5-wizard` as single step. - */ - SingleStep = "SingleStep", - } -} - -declare module "sap/ui/webc/fiori/Bar" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IBar, BarDesign } from "sap/ui/webc/fiori/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { CSSSize } from "sap/ui/core/library"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The Bar is a container which is primarily used to hold titles, buttons and input elements and - * its design and functionality is the basis for page headers and footers. The component consists of three - * areas to hold its content - startContent slot, default slot and endContent slot. It has the capability - * to center content, such as a title, while having other components on the left and right side. - * - * Usage: With the use of the design property, you can set the style of the Bar to appear designed like - * a Header, Subheader, Footer and FloatingFooter. - * **Note:** Do not place a Bar inside another Bar or inside any bar-like component. Doing so may cause - * unpredictable behavior. - * - * Responsive Behavior: The default slot will be centered in the available space between the startContent - * and the endContent areas, therefore it might not always be centered in the entire bar. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.fiori.Bar` exposes the following CSS Shadow Parts: - * - bar - Used to style the wrapper of the content of the component - * - * Keyboard Handling: - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Bar extends WebComponent implements IBar { - __implements__sap_ui_webc_fiori_IBar: boolean; - /** - * Constructor for a new `Bar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $BarSettings - ); - /** - * Constructor for a new `Bar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $BarSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.Bar with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.Bar. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some endContent to the aggregation {@link #getEndContent endContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addEndContent( - /** - * The endContent to add; if empty, nothing is inserted - */ - oEndContent: Control - ): this; - /** - * Adds some middleContent to the aggregation {@link #getMiddleContent middleContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addMiddleContent( - /** - * The middleContent to add; if empty, nothing is inserted - */ - oMiddleContent: Control - ): this; - /** - * Adds some startContent to the aggregation {@link #getStartContent startContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addStartContent( - /** - * The startContent to add; if empty, nothing is inserted - */ - oStartContent: Control - ): this; - /** - * Destroys all the endContent in the aggregation {@link #getEndContent endContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyEndContent(): this; - /** - * Destroys all the middleContent in the aggregation {@link #getMiddleContent middleContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyMiddleContent(): this; - /** - * Destroys all the startContent in the aggregation {@link #getStartContent startContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyStartContent(): this; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component's design. - * - * Default value is `Header`. - * - * - * @returns Value of property `design` - */ - getDesign(): BarDesign; - /** - * Gets content of aggregation {@link #getEndContent endContent}. - * - * Defines the content at the end of the bar. - */ - getEndContent(): Control[]; - /** - * Gets content of aggregation {@link #getMiddleContent middleContent}. - * - * Defines the content in the middle of the bar. - */ - getMiddleContent(): Control[]; - /** - * Gets content of aggregation {@link #getStartContent startContent}. - * - * Defines the content at the start of the bar. - */ - getStartContent(): Control[]; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getEndContent endContent}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfEndContent( - /** - * The endContent whose index is looked for - */ - oEndContent: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getMiddleContent middleContent}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfMiddleContent( - /** - * The middleContent whose index is looked for - */ - oMiddleContent: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getStartContent startContent}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfStartContent( - /** - * The startContent whose index is looked for - */ - oStartContent: Control - ): int; - /** - * Inserts a endContent into the aggregation {@link #getEndContent endContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertEndContent( - /** - * The endContent to insert; if empty, nothing is inserted - */ - oEndContent: Control, - /** - * The `0`-based index the endContent should be inserted at; for a negative value of `iIndex`, the endContent - * is inserted at position 0; for a value greater than the current size of the aggregation, the endContent - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a middleContent into the aggregation {@link #getMiddleContent middleContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertMiddleContent( - /** - * The middleContent to insert; if empty, nothing is inserted - */ - oMiddleContent: Control, - /** - * The `0`-based index the middleContent should be inserted at; for a negative value of `iIndex`, the middleContent - * is inserted at position 0; for a value greater than the current size of the aggregation, the middleContent - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a startContent into the aggregation {@link #getStartContent startContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertStartContent( - /** - * The startContent to insert; if empty, nothing is inserted - */ - oStartContent: Control, - /** - * The `0`-based index the startContent should be inserted at; for a negative value of `iIndex`, the startContent - * is inserted at position 0; for a value greater than the current size of the aggregation, the startContent - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getEndContent endContent}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllEndContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getMiddleContent middleContent}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllMiddleContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getStartContent startContent}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllStartContent(): Control[]; - /** - * Removes a endContent from the aggregation {@link #getEndContent endContent}. - * - * - * @returns The removed endContent or `null` - */ - removeEndContent( - /** - * The endContent to remove or its index or id - */ - vEndContent: int | string | Control - ): Control | null; - /** - * Removes a middleContent from the aggregation {@link #getMiddleContent middleContent}. - * - * - * @returns The removed middleContent or `null` - */ - removeMiddleContent( - /** - * The middleContent to remove or its index or id - */ - vMiddleContent: int | string | Control - ): Control | null; - /** - * Removes a startContent from the aggregation {@link #getStartContent startContent}. - * - * - * @returns The removed startContent or `null` - */ - removeStartContent( - /** - * The startContent to remove or its index or id - */ - vStartContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component's design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Header`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: BarDesign | keyof typeof BarDesign - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Bar constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $BarSettings extends $WebComponentSettings { - /** - * Defines the component's design. - */ - design?: - | (BarDesign | keyof typeof BarDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content at the end of the bar. - */ - endContent?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the content in the middle of the bar. - */ - middleContent?: - | Control[] - | Control - | AggregationBindingInfo - | `{${string}}`; - - /** - * Defines the content at the start of the bar. - */ - startContent?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/fiori/BarcodeScannerDialog" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `BarcodeScannerDialog` component provides barcode scanning functionality for all devices that support - * the `MediaDevices.getUserMedia()` native API. Opening the dialog launches the device camera and scans - * for known barcode formats. - * - * A `scanSuccess` event fires whenever a barcode is identified and a `scanError` event fires when the - * scan failed (for example, due to missing permisions). - * - * Internally, the component uses the zxing-js/library third party OSS. - * - * For a list of supported barcode formats, see the {@link https://github.com/zxing-js/library zxing-js/library } - * documentation. - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class BarcodeScannerDialog extends WebComponent { - /** - * Constructor for a new `BarcodeScannerDialog`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $BarcodeScannerDialogSettings - ); - /** - * Constructor for a new `BarcodeScannerDialog`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $BarcodeScannerDialogSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.BarcodeScannerDialog with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.BarcodeScannerDialog. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:scanError scanError} event of this `sap.ui.webc.fiori.BarcodeScannerDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.BarcodeScannerDialog` itself. - * - * Fires when the scan fails with error. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachScanError( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: BarcodeScannerDialog$ScanErrorEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.BarcodeScannerDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:scanError scanError} event of this `sap.ui.webc.fiori.BarcodeScannerDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.BarcodeScannerDialog` itself. - * - * Fires when the scan fails with error. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachScanError( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: BarcodeScannerDialog$ScanErrorEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.BarcodeScannerDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:scanSuccess scanSuccess} event of this `sap.ui.webc.fiori.BarcodeScannerDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.BarcodeScannerDialog` itself. - * - * Fires when the scan is completed successfuuly. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachScanSuccess( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: BarcodeScannerDialog$ScanSuccessEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.BarcodeScannerDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:scanSuccess scanSuccess} event of this `sap.ui.webc.fiori.BarcodeScannerDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.BarcodeScannerDialog` itself. - * - * Fires when the scan is completed successfuuly. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachScanSuccess( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: BarcodeScannerDialog$ScanSuccessEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.BarcodeScannerDialog` - * itself - */ - oListener?: object - ): this; - /** - * Closes the dialog and the scan session. - */ - close(): void; - /** - * Detaches event handler `fnFunction` from the {@link #event:scanError scanError} event of this `sap.ui.webc.fiori.BarcodeScannerDialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachScanError( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: BarcodeScannerDialog$ScanErrorEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:scanSuccess scanSuccess} event of this `sap.ui.webc.fiori.BarcodeScannerDialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachScanSuccess( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: BarcodeScannerDialog$ScanSuccessEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:scanError scanError} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireScanError( - /** - * Parameters to pass along with the event - */ - mParameters?: BarcodeScannerDialog$ScanErrorEventParameters - ): this; - /** - * Fires event {@link #event:scanSuccess scanSuccess} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireScanSuccess( - /** - * Parameters to pass along with the event - */ - mParameters?: BarcodeScannerDialog$ScanSuccessEventParameters - ): this; - /** - * Shows a dialog with the camera videostream. Starts a scan session. - */ - show(): void; - } - /** - * Describes the settings that can be provided to the BarcodeScannerDialog constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $BarcodeScannerDialogSettings extends $WebComponentSettings { - /** - * Fires when the scan fails with error. - */ - scanError?: (oEvent: BarcodeScannerDialog$ScanErrorEvent) => void; - - /** - * Fires when the scan is completed successfuuly. - */ - scanSuccess?: (oEvent: BarcodeScannerDialog$ScanSuccessEvent) => void; - } - - /** - * Parameters of the BarcodeScannerDialog#scanError event. - */ - export interface BarcodeScannerDialog$ScanErrorEventParameters { - /** - * the error message - */ - message?: string; - } - - /** - * Event object of the BarcodeScannerDialog#scanError event. - */ - export type BarcodeScannerDialog$ScanErrorEvent = Event< - BarcodeScannerDialog$ScanErrorEventParameters, - BarcodeScannerDialog - >; - - /** - * Parameters of the BarcodeScannerDialog#scanSuccess event. - */ - export interface BarcodeScannerDialog$ScanSuccessEventParameters { - /** - * the scan result as string - */ - text?: string; - - /** - * the scan result as a Uint8Array - */ - rawBytes?: object; - } - - /** - * Event object of the BarcodeScannerDialog#scanSuccess event. - */ - export type BarcodeScannerDialog$ScanSuccessEvent = Event< - BarcodeScannerDialog$ScanSuccessEventParameters, - BarcodeScannerDialog - >; -} - -declare module "sap/ui/webc/fiori/DynamicSideContent" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - SideContentFallDown, - SideContentPosition, - SideContentVisibility, - } from "sap/ui/webc/fiori/library"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The DynamicSideContent (`sap.ui.webc.fiori.DynamicSideContent`) is a layout component that allows additional - * content to be displayed in a way that flexibly adapts to different screen sizes. The side content appears - * in a container next to or directly below the main content (it doesn't overlay). When the side content - * is triggered, the main content becomes narrower (if appearing side-by-side). The side content contains - * a separate scrollbar when appearing next to the main content. - * - * Usage: - * - * When to use? - * - * Use this component if you want to display relevant information that is not critical for users to complete - * a task. Users should have access to all the key functions and critical information in the app even if - * they do not see the side content. This is important because on smaller screen sizes it may be difficult - * to display the side content in a way that is easily accessible for the user. - * - * When not to use? - * - * Don't use it if you want to display navigation or critical information that prevents users from completing - * a task when they have no access to the side content. - * - * Responsive Behavior: - * - * Screen width > 1440px - * - * - * - Main vs. side content ratio is 75 vs. 25 percent (with a minimum of 320px each). - * - If the application defines a trigger, the side content can be hidden. - * - * Screen width <= 1440px and> 1024px - * - * - * - Main vs. side content ratio is 66.666 vs. 33.333 percent (with a minimum of 320px each). If the side - * content width falls below 320 px, it automatically slides under the main content, unless the app development - * team specifies that it should disappear. - * - * Screen width <= 1024px and> 720px - * - * - * - The side content ratio is fixed to 340px, and the main content takes the rest of the width. Only - * if the `sideContentFallDown` is set to `OnMinimumWidth` and screen width is <= 960px and> 720px the side - * content falls below the main content. - * - * Screen width <= 720px (for example on a mobile device) - * - In this case, the side content automatically disappears from the screen (unless specified to stay - * under the content by setting of `sideContentVisibility` property to `AlwaysShow`) and can be triggered - * from a pre-set trigger (specified within the app). When the side content is triggered, it replaces the - * main content. We recommend that you always place the trigger for the side content in the same location, - * such as in the app footer. - * - * A special case allows switching the comparison mode between the main and side content. In this case, - * the screen is split into 50:50 percent for main vs. side content. The responsive behavior of the equal - * split is the same as in the standard view - the side content disappears on screen widths of less than - * 720 px and can only be viewed by triggering it. - * - * @since 1.99.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export default class DynamicSideContent extends WebComponent { - /** - * Constructor for a new `DynamicSideContent`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $DynamicSideContentSettings - ); - /** - * Constructor for a new `DynamicSideContent`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $DynamicSideContentSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.DynamicSideContent with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.DynamicSideContent. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some sideContent to the aggregation {@link #getSideContent sideContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addSideContent( - /** - * The sideContent to add; if empty, nothing is inserted - */ - oSideContent: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:layoutChange layoutChange} event of this `sap.ui.webc.fiori.DynamicSideContent`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.DynamicSideContent` itself. - * - * Fires when the current breakpoint has been changed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLayoutChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DynamicSideContent$LayoutChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.DynamicSideContent` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:layoutChange layoutChange} event of this `sap.ui.webc.fiori.DynamicSideContent`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.DynamicSideContent` itself. - * - * Fires when the current breakpoint has been changed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLayoutChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DynamicSideContent$LayoutChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.DynamicSideContent` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys all the sideContent in the aggregation {@link #getSideContent sideContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySideContent(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:layoutChange layoutChange} event of this `sap.ui.webc.fiori.DynamicSideContent`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachLayoutChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: DynamicSideContent$LayoutChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:layoutChange layoutChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireLayoutChange( - /** - * Parameters to pass along with the event - */ - mParameters?: DynamicSideContent$LayoutChangeEventParameters - ): this; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the main content. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getEqualSplit equalSplit}. - * - * Defines whether the component is in equal split mode. In this mode, the side and the main content take - * 50:50 percent of the container on all screen sizes except for phone, where the main and side contents - * are switching visibility using the toggle method. - * - * Default value is `false`. - * - * - * @returns Value of property `equalSplit` - */ - getEqualSplit(): boolean; - /** - * Gets current value of property {@link #getHideMainContent hideMainContent}. - * - * Defines the visibility of the main content. - * - * Default value is `false`. - * - * - * @returns Value of property `hideMainContent` - */ - getHideMainContent(): boolean; - /** - * Gets current value of property {@link #getHideSideContent hideSideContent}. - * - * Defines the visibility of the side content. - * - * Default value is `false`. - * - * - * @returns Value of property `hideSideContent` - */ - getHideSideContent(): boolean; - /** - * Gets content of aggregation {@link #getSideContent sideContent}. - * - * Defines the side content. - */ - getSideContent(): Control[]; - /** - * Gets current value of property {@link #getSideContentFallDown sideContentFallDown}. - * - * Defines on which breakpoints the side content falls down below the main content. - * - * - * - * **The available values are:** - * - * - * - `BelowXL` - * - `BelowL` - * - `BelowM` - * - `OnMinimumWidth` - * - * Default value is `OnMinimumWidth`. - * - * - * @returns Value of property `sideContentFallDown` - */ - getSideContentFallDown(): SideContentFallDown; - /** - * Gets current value of property {@link #getSideContentPosition sideContentPosition}. - * - * Defines whether the side content is positioned before the main content (left side in LTR mode), or after - * the the main content (right side in LTR mode). - * - * - * - * **The available values are:** - * - * - * - `Start` - * - `End` - * - * Default value is `End`. - * - * - * @returns Value of property `sideContentPosition` - */ - getSideContentPosition(): SideContentPosition; - /** - * Gets current value of property {@link #getSideContentVisibility sideContentVisibility}. - * - * Defines on which breakpoints the side content is visible. - * - * - * - * **The available values are:** - * - * - * - `AlwaysShow` - * - `ShowAboveL` - * - `ShowAboveM` - * - `ShowAboveS` - * - `NeverShow` - * - * Default value is `ShowAboveS`. - * - * - * @returns Value of property `sideContentVisibility` - */ - getSideContentVisibility(): SideContentVisibility; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getSideContent sideContent}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfSideContent( - /** - * The sideContent whose index is looked for - */ - oSideContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a sideContent into the aggregation {@link #getSideContent sideContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertSideContent( - /** - * The sideContent to insert; if empty, nothing is inserted - */ - oSideContent: Control, - /** - * The `0`-based index the sideContent should be inserted at; for a negative value of `iIndex`, the sideContent - * is inserted at position 0; for a value greater than the current size of the aggregation, the sideContent - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getSideContent sideContent}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllSideContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a sideContent from the aggregation {@link #getSideContent sideContent}. - * - * - * @returns The removed sideContent or `null` - */ - removeSideContent( - /** - * The sideContent to remove or its index or id - */ - vSideContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getEqualSplit equalSplit}. - * - * Defines whether the component is in equal split mode. In this mode, the side and the main content take - * 50:50 percent of the container on all screen sizes except for phone, where the main and side contents - * are switching visibility using the toggle method. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEqualSplit( - /** - * New value for property `equalSplit` - */ - bEqualSplit?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideMainContent hideMainContent}. - * - * Defines the visibility of the main content. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideMainContent( - /** - * New value for property `hideMainContent` - */ - bHideMainContent?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideSideContent hideSideContent}. - * - * Defines the visibility of the side content. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideSideContent( - /** - * New value for property `hideSideContent` - */ - bHideSideContent?: boolean - ): this; - /** - * Sets a new value for property {@link #getSideContentFallDown sideContentFallDown}. - * - * Defines on which breakpoints the side content falls down below the main content. - * - * - * - * **The available values are:** - * - * - * - `BelowXL` - * - `BelowL` - * - `BelowM` - * - `OnMinimumWidth` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `OnMinimumWidth`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSideContentFallDown( - /** - * New value for property `sideContentFallDown` - */ - sSideContentFallDown?: - | SideContentFallDown - | keyof typeof SideContentFallDown - ): this; - /** - * Sets a new value for property {@link #getSideContentPosition sideContentPosition}. - * - * Defines whether the side content is positioned before the main content (left side in LTR mode), or after - * the the main content (right side in LTR mode). - * - * - * - * **The available values are:** - * - * - * - `Start` - * - `End` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `End`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSideContentPosition( - /** - * New value for property `sideContentPosition` - */ - sSideContentPosition?: - | SideContentPosition - | keyof typeof SideContentPosition - ): this; - /** - * Sets a new value for property {@link #getSideContentVisibility sideContentVisibility}. - * - * Defines on which breakpoints the side content is visible. - * - * - * - * **The available values are:** - * - * - * - `AlwaysShow` - * - `ShowAboveL` - * - `ShowAboveM` - * - `ShowAboveS` - * - `NeverShow` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `ShowAboveS`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSideContentVisibility( - /** - * New value for property `sideContentVisibility` - */ - sSideContentVisibility?: - | SideContentVisibility - | keyof typeof SideContentVisibility - ): this; - /** - * Toggles visibility of main and side contents on S screen size (mobile device). - */ - toggleContents(): void; - } - /** - * Describes the settings that can be provided to the DynamicSideContent constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export interface $DynamicSideContentSettings extends $WebComponentSettings { - /** - * Defines whether the component is in equal split mode. In this mode, the side and the main content take - * 50:50 percent of the container on all screen sizes except for phone, where the main and side contents - * are switching visibility using the toggle method. - */ - equalSplit?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visibility of the main content. - */ - hideMainContent?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visibility of the side content. - */ - hideSideContent?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines on which breakpoints the side content falls down below the main content. - * - * - * - * **The available values are:** - * - * - * - `BelowXL` - * - `BelowL` - * - `BelowM` - * - `OnMinimumWidth` - */ - sideContentFallDown?: - | (SideContentFallDown | keyof typeof SideContentFallDown) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the side content is positioned before the main content (left side in LTR mode), or after - * the the main content (right side in LTR mode). - * - * - * - * **The available values are:** - * - * - * - `Start` - * - `End` - */ - sideContentPosition?: - | (SideContentPosition | keyof typeof SideContentPosition) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines on which breakpoints the side content is visible. - * - * - * - * **The available values are:** - * - * - * - `AlwaysShow` - * - `ShowAboveL` - * - `ShowAboveM` - * - `ShowAboveS` - * - `NeverShow` - */ - sideContentVisibility?: - | (SideContentVisibility | keyof typeof SideContentVisibility) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the main content. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the side content. - */ - sideContent?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Fires when the current breakpoint has been changed. - */ - layoutChange?: (oEvent: DynamicSideContent$LayoutChangeEvent) => void; - } - - /** - * Parameters of the DynamicSideContent#layoutChange event. - */ - export interface DynamicSideContent$LayoutChangeEventParameters { - /** - * the current breakpoint. - */ - currentBreakpoint?: string; - - /** - * the breakpoint that was active before change to current breakpoint. - */ - previousBreakpoint?: string; - - /** - * visibility of the main content. - */ - mainContentVisible?: boolean; - - /** - * visibility of the side content. - */ - sideContentVisible?: boolean; - } - - /** - * Event object of the DynamicSideContent#layoutChange event. - */ - export type DynamicSideContent$LayoutChangeEvent = Event< - DynamicSideContent$LayoutChangeEventParameters, - DynamicSideContent - >; -} - -declare module "sap/ui/webc/fiori/FilterItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFilterItem, IFilterItemOption } from "sap/ui/webc/fiori/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * Usage: - * - * @since 1.97.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export default class FilterItem extends WebComponent implements IFilterItem { - __implements__sap_ui_webc_fiori_IFilterItem: boolean; - /** - * Constructor for a new `FilterItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $FilterItemSettings - ); - /** - * Constructor for a new `FilterItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $FilterItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.FilterItem with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.FilterItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some value to the aggregation {@link #getValues values}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addValue( - /** - * The value to add; if empty, nothing is inserted - */ - oValue: IFilterItemOption - ): this; - /** - * Destroys all the values in the aggregation {@link #getValues values}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyValues(): this; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the additional text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets content of aggregation {@link #getValues values}. - * - * Defines the `values` list. - */ - getValues(): IFilterItemOption[]; - /** - * Checks for the provided `sap.ui.webc.fiori.IFilterItemOption` in the aggregation {@link #getValues values}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfValue( - /** - * The value whose index is looked for - */ - oValue: IFilterItemOption - ): int; - /** - * Inserts a value into the aggregation {@link #getValues values}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertValue( - /** - * The value to insert; if empty, nothing is inserted - */ - oValue: IFilterItemOption, - /** - * The `0`-based index the value should be inserted at; for a negative value of `iIndex`, the value is inserted - * at position 0; for a value greater than the current size of the aggregation, the value is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getValues values}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllValues(): IFilterItemOption[]; - /** - * Removes a value from the aggregation {@link #getValues values}. - * - * - * @returns The removed value or `null` - */ - removeValue( - /** - * The value to remove or its index or id - */ - vValue: int | string | IFilterItemOption - ): IFilterItemOption | null; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the additional text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the FilterItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export interface $FilterItemSettings extends $WebComponentSettings { - /** - * Defines the additional text of the component. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the `values` list. - */ - values?: - | IFilterItemOption[] - | IFilterItemOption - | AggregationBindingInfo - | `{${string}}`; - } -} - -declare module "sap/ui/webc/fiori/FilterItemOption" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFilterItemOption } from "sap/ui/webc/fiori/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * Usage: - * - * @since 1.97.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export default class FilterItemOption - extends WebComponent - implements IFilterItemOption - { - __implements__sap_ui_webc_fiori_IFilterItemOption: boolean; - /** - * Constructor for a new `FilterItemOption`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $FilterItemOptionSettings - ); - /** - * Constructor for a new `FilterItemOption`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $FilterItemOptionSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.FilterItemOption with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.FilterItemOption. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines if the component is selected. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines if the component is selected. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the FilterItemOption constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export interface $FilterItemOptionSettings extends $WebComponentSettings { - /** - * Defines if the component is selected. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/fiori/FlexibleColumnLayout" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Control from "sap/ui/core/Control"; - - import { CSSSize } from "sap/ui/core/library"; - - import { FCLLayout } from "sap/ui/webc/fiori/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `FlexibleColumnLayout` implements the list-detail-detail paradigm by displaying up to three pages - * in separate columns. There are several possible layouts that can be changed either with the component - * API, or by pressing the arrows, displayed between the columns. - * - * Usage: - * - * Use this component for applications that need to display several logical levels of related information - * side by side (e.g. list of items, item, sub-item, etc.). The Component is flexible in a sense that the - * application can focus the user's attention on one particular column. - * - * Responsive Behavior: - * - * The `FlexibleColumnLayout` automatically displays the maximum possible number of columns based on `layout` - * property and the window size. The component would display 1 column for window size smaller than 599px, - * up to two columns between 599px and 1023px, and 3 columns for sizes bigger than 1023px. - * - * - * - * Keyboard Handling: - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class FlexibleColumnLayout extends WebComponent { - /** - * Constructor for a new `FlexibleColumnLayout`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $FlexibleColumnLayoutSettings - ); - /** - * Constructor for a new `FlexibleColumnLayout`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $FlexibleColumnLayoutSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.FlexibleColumnLayout with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.FlexibleColumnLayout. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:layoutChange layoutChange} event of this `sap.ui.webc.fiori.FlexibleColumnLayout`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.FlexibleColumnLayout` itself. - * - * Fired when the layout changes via user interaction by clicking the arrows or by changing the component - * size due to resizing. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLayoutChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: FlexibleColumnLayout$LayoutChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.FlexibleColumnLayout` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:layoutChange layoutChange} event of this `sap.ui.webc.fiori.FlexibleColumnLayout`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.FlexibleColumnLayout` itself. - * - * Fired when the layout changes via user interaction by clicking the arrows or by changing the component - * size due to resizing. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLayoutChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: FlexibleColumnLayout$LayoutChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.FlexibleColumnLayout` - * itself - */ - oListener?: object - ): this; - /** - * Destroys the endColumn in the aggregation {@link #getEndColumn endColumn}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyEndColumn(): this; - /** - * Destroys the midColumn in the aggregation {@link #getMidColumn midColumn}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyMidColumn(): this; - /** - * Destroys the startColumn in the aggregation {@link #getStartColumn startColumn}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyStartColumn(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:layoutChange layoutChange} event of this `sap.ui.webc.fiori.FlexibleColumnLayout`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachLayoutChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: FlexibleColumnLayout$LayoutChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:layoutChange layoutChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireLayoutChange( - /** - * Parameters to pass along with the event - */ - mParameters?: FlexibleColumnLayout$LayoutChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibilityRoles accessibilityRoles}. - * - * An object of strings that defines additional accessibility roles for further customization. - * - * It supports the following fields: - `startColumnRole`: the accessibility role for the `startColumn` - - * `startArrowContainerRole`: the accessibility role for the first arrow container (between the `begin` - * and `mid` columns) - `midColumnRole`: the accessibility role for the `midColumn` - `endArrowContainerRole`: - * the accessibility role for the second arrow container (between the `mid` and `end` columns) - `endColumnRole`: - * the accessibility role for the `endColumn` - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityRoles` - */ - getAccessibilityRoles(): object; - /** - * Gets current value of property {@link #getAccessibilityTexts accessibilityTexts}. - * - * An object of strings that defines several additional accessibility texts for even further customization. - * - * It supports the following fields: - `startColumnAccessibleName`: the accessibility name for the `startColumn` - * region - `midColumnAccessibleName`: the accessibility name for the `midColumn` region - `endColumnAccessibleName`: - * the accessibility name for the `endColumn` region - `startArrowLeftText`: the text that the first arrow - * (between the `begin` and `mid` columns) will have when pointing to the left - `startArrowRightText`: - * the text that the first arrow (between the `begin` and `mid` columns) will have when pointing to the - * right - `endArrowLeftText`: the text that the second arrow (between the `mid` and `end` columns) will - * have when pointing to the left - `endArrowRightText`: the text that the second arrow (between the `mid` - * and `end` columns) will have when pointing to the right - `startArrowContainerAccessibleName`: the text - * that the first arrow container (between the `begin` and `mid` columns) will have as `aria-label` - `endArrowContainerAccessibleName`: - * the text that the second arrow container (between the `mid` and `end` columns) will have as `aria-label` - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityTexts` - */ - getAccessibilityTexts(): object; - /** - * Returns the current column layout, based on both the `layout` property and the screen size. - * - * **For example:** ["67%", "33%", 0], ["100%", 0, 0], ["25%", "50%", "25%"], etc, where the numbers represents - * the width of the start, middle and end columns. - */ - getColumnLayout(): void; - /** - * Gets content of aggregation {@link #getEndColumn endColumn}. - * - * Defines the content in the end column. - */ - getEndColumn(): Control; - /** - * Returns if the `end` column is visible. - */ - getEndColumnVisible(): void; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getHideArrows hideArrows}. - * - * Defines the visibility of the arrows, used for expanding and shrinking the columns. - * - * Default value is `false`. - * - * - * @returns Value of property `hideArrows` - */ - getHideArrows(): boolean; - /** - * Gets current value of property {@link #getLayout layout}. - * - * Defines the columns layout and their proportion. - * - * **Note:** The layout also depends on the screen size - one column for screens smaller than 599px, two - * columns between 599px and 1023px and three columns for sizes bigger than 1023px. - * - * Available options are: - * - `OneColumn` - * - `TwoColumnsStartExpanded` - * - `TwoColumnsMidExpanded` - * - `ThreeColumnsMidExpanded` - * - `ThreeColumnsEndExpanded` - * - `ThreeColumnsStartExpandedEndHidden` - * - `ThreeColumnsMidExpandedEndHidden` - * - `MidColumnFullScreen` - * - `EndColumnFullScreen` - * - * **For example:** layout=`TwoColumnsStartExpanded` means the layout will display up to two columns in - * 67%/33% proportion. - * - * Default value is `OneColumn`. - * - * - * @returns Value of property `layout` - */ - getLayout(): FCLLayout; - /** - * Gets content of aggregation {@link #getMidColumn midColumn}. - * - * Defines the content in the middle column. - */ - getMidColumn(): Control; - /** - * Returns if the `middle` column is visible. - */ - getMidColumnVisible(): void; - /** - * Gets content of aggregation {@link #getStartColumn startColumn}. - * - * Defines the content in the start column. - */ - getStartColumn(): Control; - /** - * Returns if the `start` column is visible. - */ - getStartColumnVisible(): void; - /** - * Returns the number of currently visible columns. - */ - getVisibleColumns(): void; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getAccessibilityRoles accessibilityRoles}. - * - * An object of strings that defines additional accessibility roles for further customization. - * - * It supports the following fields: - `startColumnRole`: the accessibility role for the `startColumn` - - * `startArrowContainerRole`: the accessibility role for the first arrow container (between the `begin` - * and `mid` columns) - `midColumnRole`: the accessibility role for the `midColumn` - `endArrowContainerRole`: - * the accessibility role for the second arrow container (between the `mid` and `end` columns) - `endColumnRole`: - * the accessibility role for the `endColumn` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityRoles( - /** - * New value for property `accessibilityRoles` - */ - oAccessibilityRoles?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibilityTexts accessibilityTexts}. - * - * An object of strings that defines several additional accessibility texts for even further customization. - * - * It supports the following fields: - `startColumnAccessibleName`: the accessibility name for the `startColumn` - * region - `midColumnAccessibleName`: the accessibility name for the `midColumn` region - `endColumnAccessibleName`: - * the accessibility name for the `endColumn` region - `startArrowLeftText`: the text that the first arrow - * (between the `begin` and `mid` columns) will have when pointing to the left - `startArrowRightText`: - * the text that the first arrow (between the `begin` and `mid` columns) will have when pointing to the - * right - `endArrowLeftText`: the text that the second arrow (between the `mid` and `end` columns) will - * have when pointing to the left - `endArrowRightText`: the text that the second arrow (between the `mid` - * and `end` columns) will have when pointing to the right - `startArrowContainerAccessibleName`: the text - * that the first arrow container (between the `begin` and `mid` columns) will have as `aria-label` - `endArrowContainerAccessibleName`: - * the text that the second arrow container (between the `mid` and `end` columns) will have as `aria-label` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityTexts( - /** - * New value for property `accessibilityTexts` - */ - oAccessibilityTexts?: object - ): this; - /** - * Sets the aggregated {@link #getEndColumn endColumn}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEndColumn( - /** - * The endColumn to set - */ - oEndColumn: Control - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getHideArrows hideArrows}. - * - * Defines the visibility of the arrows, used for expanding and shrinking the columns. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideArrows( - /** - * New value for property `hideArrows` - */ - bHideArrows?: boolean - ): this; - /** - * Sets a new value for property {@link #getLayout layout}. - * - * Defines the columns layout and their proportion. - * - * **Note:** The layout also depends on the screen size - one column for screens smaller than 599px, two - * columns between 599px and 1023px and three columns for sizes bigger than 1023px. - * - * Available options are: - * - `OneColumn` - * - `TwoColumnsStartExpanded` - * - `TwoColumnsMidExpanded` - * - `ThreeColumnsMidExpanded` - * - `ThreeColumnsEndExpanded` - * - `ThreeColumnsStartExpandedEndHidden` - * - `ThreeColumnsMidExpandedEndHidden` - * - `MidColumnFullScreen` - * - `EndColumnFullScreen` - * - * **For example:** layout=`TwoColumnsStartExpanded` means the layout will display up to two columns in - * 67%/33% proportion. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `OneColumn`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLayout( - /** - * New value for property `layout` - */ - sLayout?: FCLLayout | keyof typeof FCLLayout - ): this; - /** - * Sets the aggregated {@link #getMidColumn midColumn}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMidColumn( - /** - * The midColumn to set - */ - oMidColumn: Control - ): this; - /** - * Sets the aggregated {@link #getStartColumn startColumn}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStartColumn( - /** - * The startColumn to set - */ - oStartColumn: Control - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the FlexibleColumnLayout constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $FlexibleColumnLayoutSettings extends $WebComponentSettings { - /** - * An object of strings that defines additional accessibility roles for further customization. - * - * It supports the following fields: - `startColumnRole`: the accessibility role for the `startColumn` - - * `startArrowContainerRole`: the accessibility role for the first arrow container (between the `begin` - * and `mid` columns) - `midColumnRole`: the accessibility role for the `midColumn` - `endArrowContainerRole`: - * the accessibility role for the second arrow container (between the `mid` and `end` columns) - `endColumnRole`: - * the accessibility role for the `endColumn` - */ - accessibilityRoles?: object | PropertyBindingInfo | `{${string}}`; - - /** - * An object of strings that defines several additional accessibility texts for even further customization. - * - * It supports the following fields: - `startColumnAccessibleName`: the accessibility name for the `startColumn` - * region - `midColumnAccessibleName`: the accessibility name for the `midColumn` region - `endColumnAccessibleName`: - * the accessibility name for the `endColumn` region - `startArrowLeftText`: the text that the first arrow - * (between the `begin` and `mid` columns) will have when pointing to the left - `startArrowRightText`: - * the text that the first arrow (between the `begin` and `mid` columns) will have when pointing to the - * right - `endArrowLeftText`: the text that the second arrow (between the `mid` and `end` columns) will - * have when pointing to the left - `endArrowRightText`: the text that the second arrow (between the `mid` - * and `end` columns) will have when pointing to the right - `startArrowContainerAccessibleName`: the text - * that the first arrow container (between the `begin` and `mid` columns) will have as `aria-label` - `endArrowContainerAccessibleName`: - * the text that the second arrow container (between the `mid` and `end` columns) will have as `aria-label` - */ - accessibilityTexts?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visibility of the arrows, used for expanding and shrinking the columns. - */ - hideArrows?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the columns layout and their proportion. - * - * **Note:** The layout also depends on the screen size - one column for screens smaller than 599px, two - * columns between 599px and 1023px and three columns for sizes bigger than 1023px. - * - * Available options are: - * - `OneColumn` - * - `TwoColumnsStartExpanded` - * - `TwoColumnsMidExpanded` - * - `ThreeColumnsMidExpanded` - * - `ThreeColumnsEndExpanded` - * - `ThreeColumnsStartExpandedEndHidden` - * - `ThreeColumnsMidExpandedEndHidden` - * - `MidColumnFullScreen` - * - `EndColumnFullScreen` - * - * **For example:** layout=`TwoColumnsStartExpanded` means the layout will display up to two columns in - * 67%/33% proportion. - */ - layout?: - | (FCLLayout | keyof typeof FCLLayout) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content in the end column. - */ - endColumn?: Control; - - /** - * Defines the content in the middle column. - */ - midColumn?: Control; - - /** - * Defines the content in the start column. - */ - startColumn?: Control; - - /** - * Fired when the layout changes via user interaction by clicking the arrows or by changing the component - * size due to resizing. - */ - layoutChange?: (oEvent: FlexibleColumnLayout$LayoutChangeEvent) => void; - } - - /** - * Parameters of the FlexibleColumnLayout#layoutChange event. - */ - export interface FlexibleColumnLayout$LayoutChangeEventParameters { - /** - * The current layout - */ - layout?: FCLLayout | keyof typeof FCLLayout; - - /** - * The effective column layout, f.e [67%, 33%, 0] - */ - columnLayout?: any[]; - - /** - * Indicates if the start column is currently visible - */ - startColumnVisible?: boolean; - - /** - * Indicates if the middle column is currently visible - */ - midColumnVisible?: boolean; - - /** - * Indicates if the end column is currently visible - */ - endColumnVisible?: boolean; - - /** - * Indicates if the layout is changed via the arrows - */ - arrowsUsed?: boolean; - - /** - * Indicates if the layout is changed via resizing - */ - resize?: boolean; - } - - /** - * Event object of the FlexibleColumnLayout#layoutChange event. - */ - export type FlexibleColumnLayout$LayoutChangeEvent = Event< - FlexibleColumnLayout$LayoutChangeEventParameters, - FlexibleColumnLayout - >; -} - -declare module "sap/ui/webc/fiori/IllustratedMessage" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IButton } from "sap/ui/webc/main/library"; - - import { ID } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - IllustrationMessageType, - IllustrationMessageSize, - } from "sap/ui/webc/fiori/library"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: An IllustratedMessage is a recommended combination of a solution-oriented message, an engaging - * illustration, and conversational tone to better communicate an empty or a success state than just show - * a message alone. - * - * Each illustration has default internationalised title and subtitle texts. Also they can be managed with - * `titleText` and `subtitleText` properties. - * - * Structure: The IllustratedMessage consists of the following elements, which are displayed below each - * other in the following order: - * - * - * - * - Illustration - * - Title - * - Subtitle - * - Actions - * - * Usage: `sap.ui.webc.fiori.IllustratedMessage` is meant to be used inside container component, for example - * a `sap.ui.webc.main.Card`, a `sap.ui.webc.main.Dialog` or a `sap.ui.webc.fiori.Page` - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class IllustratedMessage extends WebComponent { - /** - * Constructor for a new `IllustratedMessage`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $IllustratedMessageSettings - ); - /** - * Constructor for a new `IllustratedMessage`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $IllustratedMessageSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.IllustratedMessage with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.IllustratedMessage. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some action to the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAction( - /** - * The action to add; if empty, nothing is inserted - */ - oAction: IButton - ): this; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Destroys all the actions in the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyActions(): this; - /** - * Destroys the subtitle in the aggregation {@link #getSubtitle subtitle}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySubtitle(): this; - /** - * Destroys the title in the aggregation {@link #getTitle title}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyTitle(): this; - /** - * Gets content of aggregation {@link #getActions actions}. - * - * Defines the component actions. - */ - getActions(): IButton[]; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getName name}. - * - * Default value is `BeforeSearch`. - * - * - * @returns Value of property `name` - */ - getName(): IllustrationMessageType; - /** - * Gets current value of property {@link #getSize size}. - * - * Determines which illustration breakpoint variant is used. - * - * Available options are: - * - `Auto` - * - `Base` - * - `Spot` - * - `Dialog` - * - `Scene` - * - * As `IllustratedMessage` adapts itself around the `Illustration`, the other elements of the component - * are displayed differently on the different breakpoints/illustration sizes. - * - * Default value is `Auto`. - * - * - * @returns Value of property `size` - */ - getSize(): IllustrationMessageSize; - /** - * Gets content of aggregation {@link #getSubtitle subtitle}. - * - * Defines the subtitle of the component. - * - * **Note:** Using this slot, the default subtitle text of illustration and the value of `subtitleText` - * property will be overwritten. - */ - getSubtitle(): Control; - /** - * Gets current value of property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle of the component. - * - * **Note:** Using this property, the default subtitle text of illustration will be overwritten. - * - * **Note:** Using `subtitle` slot, the default of this property will be overwritten. - * - * Default value is `empty string`. - * - * - * @returns Value of property `subtitleText` - */ - getSubtitleText(): string; - /** - * Gets content of aggregation {@link #getTitle title}. - * - * Defines the title of the component. - * - * **Note:** Using this slot, the default title text of illustration and the value of `title` property - * will be overwritten. - */ - getTitle(): Control; - /** - * Gets current value of property {@link #getTitleText titleText}. - * - * Defines the title of the component. - * - * **Note:** Using this property, the default title text of illustration will be overwritten. - * - * Default value is `empty string`. - * - * - * @returns Value of property `titleText` - */ - getTitleText(): string; - /** - * Checks for the provided `sap.ui.webc.main.IButton` in the aggregation {@link #getActions actions}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfAction( - /** - * The action whose index is looked for - */ - oAction: IButton - ): int; - /** - * Inserts a action into the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertAction( - /** - * The action to insert; if empty, nothing is inserted - */ - oAction: IButton, - /** - * The `0`-based index the action should be inserted at; for a negative value of `iIndex`, the action is - * inserted at position 0; for a value greater than the current size of the aggregation, the action is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Removes a action from the aggregation {@link #getActions actions}. - * - * - * @returns The removed action or `null` - */ - removeAction( - /** - * The action to remove or its index or id - */ - vAction: int | string | IButton - ): IButton | null; - /** - * Removes all the controls from the aggregation {@link #getActions actions}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllActions(): IButton[]; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getName name}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `BeforeSearch`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: IllustrationMessageType | keyof typeof IllustrationMessageType - ): this; - /** - * Sets a new value for property {@link #getSize size}. - * - * Determines which illustration breakpoint variant is used. - * - * Available options are: - * - `Auto` - * - `Base` - * - `Spot` - * - `Dialog` - * - `Scene` - * - * As `IllustratedMessage` adapts itself around the `Illustration`, the other elements of the component - * are displayed differently on the different breakpoints/illustration sizes. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Auto`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSize( - /** - * New value for property `size` - */ - sSize?: IllustrationMessageSize | keyof typeof IllustrationMessageSize - ): this; - /** - * Sets the aggregated {@link #getSubtitle subtitle}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSubtitle( - /** - * The subtitle to set - */ - oSubtitle: Control - ): this; - /** - * Sets a new value for property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle of the component. - * - * **Note:** Using this property, the default subtitle text of illustration will be overwritten. - * - * **Note:** Using `subtitle` slot, the default of this property will be overwritten. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSubtitleText( - /** - * New value for property `subtitleText` - */ - sSubtitleText?: string - ): this; - /** - * Sets the aggregated {@link #getTitle title}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitle( - /** - * The title to set - */ - oTitle: Control - ): this; - /** - * Sets a new value for property {@link #getTitleText titleText}. - * - * Defines the title of the component. - * - * **Note:** Using this property, the default title text of illustration will be overwritten. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitleText( - /** - * New value for property `titleText` - */ - sTitleText?: string - ): this; - } - /** - * Describes the settings that can be provided to the IllustratedMessage constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $IllustratedMessageSettings extends $WebComponentSettings { - name?: - | (IllustrationMessageType | keyof typeof IllustrationMessageType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines which illustration breakpoint variant is used. - * - * Available options are: - * - `Auto` - * - `Base` - * - `Spot` - * - `Dialog` - * - `Scene` - * - * As `IllustratedMessage` adapts itself around the `Illustration`, the other elements of the component - * are displayed differently on the different breakpoints/illustration sizes. - */ - size?: - | (IllustrationMessageSize | keyof typeof IllustrationMessageSize) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the subtitle of the component. - * - * **Note:** Using this property, the default subtitle text of illustration will be overwritten. - * - * **Note:** Using `subtitle` slot, the default of this property will be overwritten. - */ - subtitleText?: string | PropertyBindingInfo; - - /** - * Defines the title of the component. - * - * **Note:** Using this property, the default title text of illustration will be overwritten. - */ - titleText?: string | PropertyBindingInfo; - - /** - * Defines the component actions. - */ - actions?: IButton[] | IButton | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the subtitle of the component. - * - * **Note:** Using this slot, the default subtitle text of illustration and the value of `subtitleText` - * property will be overwritten. - */ - subtitle?: Control; - - /** - * Defines the title of the component. - * - * **Note:** Using this slot, the default title text of illustration and the value of `title` property - * will be overwritten. - */ - title?: Control; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - } -} - -declare module "sap/ui/webc/fiori/MediaGallery" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - IMediaGalleryItem, - MediaGalleryLayout, - MediaGalleryMenuHorizontalAlign, - MediaGalleryMenuVerticalAlign, - } from "sap/ui/webc/fiori/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.MediaGallery` component allows the user to browse through multimedia items. Currently, - * the supported items are images and videos. The items should be defined using the `sap.ui.webc.fiori.MediaGalleryItem` - * component. - * - * The items are initially displayed as thumbnails. When the user selects a thumbnail, the corresponding - * item is displayed in larger size. - * The component is responsive by default and adjusts the position of the menu with respect to viewport - * size, but the application is able to further customize the layout via the provided API. - * - * Keyboard Handling: The `sap.ui.webc.fiori.MediaGallery` provides advanced keyboard handling. - * When the thumbnails menu is focused the following keyboard shortcuts allow the user to navigate through - * the thumbnail items: - * - * - * - * - [UP/DOWN] - Navigates up and down the items - * - [HOME] - Navigates to first item - * - [END] - Navigates to the last item - * - [SPACE/ENTER] - Select an item - * - * - * @since 1.99.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export default class MediaGallery extends WebComponent { - /** - * Constructor for a new `MediaGallery`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MediaGallerySettings - ); - /** - * Constructor for a new `MediaGallery`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MediaGallerySettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.MediaGallery with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.MediaGallery. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IMediaGalleryItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:displayAreaClick displayAreaClick} event of - * this `sap.ui.webc.fiori.MediaGallery`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.MediaGallery` itself. - * - * Fired when the display area is clicked. - * The display area is the central area that contains the enlarged content of the currently selected item. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDisplayAreaClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.MediaGallery` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:displayAreaClick displayAreaClick} event of - * this `sap.ui.webc.fiori.MediaGallery`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.MediaGallery` itself. - * - * Fired when the display area is clicked. - * The display area is the central area that contains the enlarged content of the currently selected item. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDisplayAreaClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.MediaGallery` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:overflowClick overflowClick} event of this `sap.ui.webc.fiori.MediaGallery`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.MediaGallery` itself. - * - * Fired when the thumbnails overflow button is clicked. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOverflowClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.MediaGallery` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:overflowClick overflowClick} event of this `sap.ui.webc.fiori.MediaGallery`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.MediaGallery` itself. - * - * Fired when the thumbnails overflow button is clicked. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOverflowClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.MediaGallery` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.fiori.MediaGallery`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.MediaGallery` itself. - * - * Fired when selection is changed by user interaction. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MediaGallery$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.MediaGallery` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.fiori.MediaGallery`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.MediaGallery` itself. - * - * Fired when selection is changed by user interaction. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MediaGallery$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.MediaGallery` itself - */ - oListener?: object - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:displayAreaClick displayAreaClick} event of - * this `sap.ui.webc.fiori.MediaGallery`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachDisplayAreaClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:overflowClick overflowClick} event of this - * `sap.ui.webc.fiori.MediaGallery`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachOverflowClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.fiori.MediaGallery`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: MediaGallery$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:displayAreaClick displayAreaClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireDisplayAreaClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:overflowClick overflowClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireOverflowClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: MediaGallery$SelectionChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getInteractiveDisplayArea interactiveDisplayArea}. - * - * If enabled, a `display-area-click` event is fired when the user clicks or taps on the display area. - * The display area is the central area that contains the enlarged content of the currently selected item. - * - * Default value is `false`. - * - * - * @returns Value of property `interactiveDisplayArea` - */ - getInteractiveDisplayArea(): boolean; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the component items. - * - * - * - * **Note:** Only one selected item is allowed. - * - * - * - * **Note:** Use the `sap.ui.webc.fiori.MediaGalleryItem` component to define the desired items. - */ - getItems(): IMediaGalleryItem[]; - /** - * Gets current value of property {@link #getLayout layout}. - * - * Determines the layout of the component. - * - * Available options are: - * - `Auto` - * - `Vertical` - * - `Horizontal` - * - * Default value is `Auto`. - * - * - * @returns Value of property `layout` - */ - getLayout(): MediaGalleryLayout; - /** - * Gets current value of property {@link #getMenuHorizontalAlign menuHorizontalAlign}. - * - * Determines the horizontal alignment of the thumbnails menu vs. the central display area. - * - * Available options are: - * - `Left` - * - `Right` - * - * Default value is `Left`. - * - * - * @returns Value of property `menuHorizontalAlign` - */ - getMenuHorizontalAlign(): MediaGalleryMenuHorizontalAlign; - /** - * Gets current value of property {@link #getMenuVerticalAlign menuVerticalAlign}. - * - * Determines the vertical alignment of the thumbnails menu vs. the central display area. - * - * Available options are: - * - `Top` - * - `Bottom` - * - * Default value is `Bottom`. - * - * - * @returns Value of property `menuVerticalAlign` - */ - getMenuVerticalAlign(): MediaGalleryMenuVerticalAlign; - /** - * Gets current value of property {@link #getShowAllThumbnails showAllThumbnails}. - * - * If set to `true`, all thumbnails are rendered in a scrollable container. If `false`, only up to five - * thumbnails are rendered, followed by an overflow button that shows the count of the remaining thumbnails. - * - * Default value is `false`. - * - * - * @returns Value of property `showAllThumbnails` - */ - getShowAllThumbnails(): boolean; - /** - * Checks for the provided `sap.ui.webc.fiori.IMediaGalleryItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IMediaGalleryItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IMediaGalleryItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IMediaGalleryItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IMediaGalleryItem - ): IMediaGalleryItem | null; - /** - * Sets a new value for property {@link #getInteractiveDisplayArea interactiveDisplayArea}. - * - * If enabled, a `display-area-click` event is fired when the user clicks or taps on the display area. - * The display area is the central area that contains the enlarged content of the currently selected item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInteractiveDisplayArea( - /** - * New value for property `interactiveDisplayArea` - */ - bInteractiveDisplayArea?: boolean - ): this; - /** - * Sets a new value for property {@link #getLayout layout}. - * - * Determines the layout of the component. - * - * Available options are: - * - `Auto` - * - `Vertical` - * - `Horizontal` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Auto`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLayout( - /** - * New value for property `layout` - */ - sLayout?: MediaGalleryLayout | keyof typeof MediaGalleryLayout - ): this; - /** - * Sets a new value for property {@link #getMenuHorizontalAlign menuHorizontalAlign}. - * - * Determines the horizontal alignment of the thumbnails menu vs. the central display area. - * - * Available options are: - * - `Left` - * - `Right` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Left`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMenuHorizontalAlign( - /** - * New value for property `menuHorizontalAlign` - */ - sMenuHorizontalAlign?: - | MediaGalleryMenuHorizontalAlign - | keyof typeof MediaGalleryMenuHorizontalAlign - ): this; - /** - * Sets a new value for property {@link #getMenuVerticalAlign menuVerticalAlign}. - * - * Determines the vertical alignment of the thumbnails menu vs. the central display area. - * - * Available options are: - * - `Top` - * - `Bottom` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Bottom`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMenuVerticalAlign( - /** - * New value for property `menuVerticalAlign` - */ - sMenuVerticalAlign?: - | MediaGalleryMenuVerticalAlign - | keyof typeof MediaGalleryMenuVerticalAlign - ): this; - /** - * Sets a new value for property {@link #getShowAllThumbnails showAllThumbnails}. - * - * If set to `true`, all thumbnails are rendered in a scrollable container. If `false`, only up to five - * thumbnails are rendered, followed by an overflow button that shows the count of the remaining thumbnails. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowAllThumbnails( - /** - * New value for property `showAllThumbnails` - */ - bShowAllThumbnails?: boolean - ): this; - } - /** - * Describes the settings that can be provided to the MediaGallery constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export interface $MediaGallerySettings extends $WebComponentSettings { - /** - * If enabled, a `display-area-click` event is fired when the user clicks or taps on the display area. - * The display area is the central area that contains the enlarged content of the currently selected item. - */ - interactiveDisplayArea?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the layout of the component. - * - * Available options are: - * - `Auto` - * - `Vertical` - * - `Horizontal` - */ - layout?: - | (MediaGalleryLayout | keyof typeof MediaGalleryLayout) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines the horizontal alignment of the thumbnails menu vs. the central display area. - * - * Available options are: - * - `Left` - * - `Right` - */ - menuHorizontalAlign?: - | ( - | MediaGalleryMenuHorizontalAlign - | keyof typeof MediaGalleryMenuHorizontalAlign - ) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines the vertical alignment of the thumbnails menu vs. the central display area. - * - * Available options are: - * - `Top` - * - `Bottom` - */ - menuVerticalAlign?: - | ( - | MediaGalleryMenuVerticalAlign - | keyof typeof MediaGalleryMenuVerticalAlign - ) - | PropertyBindingInfo - | `{${string}}`; - - /** - * If set to `true`, all thumbnails are rendered in a scrollable container. If `false`, only up to five - * thumbnails are rendered, followed by an overflow button that shows the count of the remaining thumbnails. - */ - showAllThumbnails?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the component items. - * - * - * - * **Note:** Only one selected item is allowed. - * - * - * - * **Note:** Use the `sap.ui.webc.fiori.MediaGalleryItem` component to define the desired items. - */ - items?: - | IMediaGalleryItem[] - | IMediaGalleryItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the display area is clicked. - * The display area is the central area that contains the enlarged content of the currently selected item. - */ - displayAreaClick?: (oEvent: Event) => void; - - /** - * Fired when the thumbnails overflow button is clicked. - */ - overflowClick?: (oEvent: Event) => void; - - /** - * Fired when selection is changed by user interaction. - */ - selectionChange?: (oEvent: MediaGallery$SelectionChangeEvent) => void; - } - - /** - * Parameters of the MediaGallery#displayAreaClick event. - */ - export interface MediaGallery$DisplayAreaClickEventParameters {} - - /** - * Event object of the MediaGallery#displayAreaClick event. - */ - export type MediaGallery$DisplayAreaClickEvent = Event< - MediaGallery$DisplayAreaClickEventParameters, - MediaGallery - >; - - /** - * Parameters of the MediaGallery#overflowClick event. - */ - export interface MediaGallery$OverflowClickEventParameters {} - - /** - * Event object of the MediaGallery#overflowClick event. - */ - export type MediaGallery$OverflowClickEvent = Event< - MediaGallery$OverflowClickEventParameters, - MediaGallery - >; - - /** - * Parameters of the MediaGallery#selectionChange event. - */ - export interface MediaGallery$SelectionChangeEventParameters { - /** - * the selected item. - */ - item?: HTMLElement; - } - - /** - * Event object of the MediaGallery#selectionChange event. - */ - export type MediaGallery$SelectionChangeEvent = Event< - MediaGallery$SelectionChangeEventParameters, - MediaGallery - >; -} - -declare module "sap/ui/webc/fiori/MediaGalleryItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - IMediaGalleryItem, - MediaGalleryItemLayout, - } from "sap/ui/webc/fiori/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.fiori.MediaGalleryItem` web component represents the items displayed in the - * `sap.ui.webc.fiori.MediaGallery` web component. - * - * **Note:** `sap.ui.webc.fiori.MediaGalleryItem` is not supported when used outside of `sap.ui.webc.fiori.MediaGallery`. - * - * - * - * - * Keyboard Handling: The `sap.ui.webc.fiori.MediaGallery` provides advanced keyboard handling. When focused, - * the user can use the following keyboard shortcuts in order to perform a navigation: - * - * - * - * - [SPACE/ENTER/RETURN] - Trigger `ui5-click` event - * - * @since 1.99.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export default class MediaGalleryItem - extends WebComponent - implements IMediaGalleryItem - { - __implements__sap_ui_webc_fiori_IMediaGalleryItem: boolean; - /** - * Constructor for a new `MediaGalleryItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MediaGalleryItemSettings - ); - /** - * Constructor for a new `MediaGalleryItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MediaGalleryItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.MediaGalleryItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.MediaGalleryItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Destroys the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys the thumbnail in the aggregation {@link #getThumbnail thumbnail}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyThumbnail(): this; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the component. - */ - getContent(): Control; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getLayout layout}. - * - * Determines the layout of the item container. - * - * Available options are: - * - `Square` - * - `Wide` - * - * Default value is `Square`. - * - * - * @returns Value of property `layout` - */ - getLayout(): MediaGalleryItemLayout; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets content of aggregation {@link #getThumbnail thumbnail}. - * - * Defines the content of the thumbnail. - */ - getThumbnail(): Control; - /** - * Sets the aggregated {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setContent( - /** - * The content to set - */ - oContent: Control - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getLayout layout}. - * - * Determines the layout of the item container. - * - * Available options are: - * - `Square` - * - `Wide` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Square`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLayout( - /** - * New value for property `layout` - */ - sLayout?: MediaGalleryItemLayout | keyof typeof MediaGalleryItemLayout - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets the aggregated {@link #getThumbnail thumbnail}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setThumbnail( - /** - * The thumbnail to set - */ - oThumbnail: Control - ): this; - } - /** - * Describes the settings that can be provided to the MediaGalleryItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export interface $MediaGalleryItemSettings extends $WebComponentSettings { - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the layout of the item container. - * - * Available options are: - * - `Square` - * - `Wide` - */ - layout?: - | (MediaGalleryItemLayout | keyof typeof MediaGalleryItemLayout) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the selected state of the component. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the component. - */ - content?: Control; - - /** - * Defines the content of the thumbnail. - */ - thumbnail?: Control; - } -} - -declare module "sap/ui/webc/fiori/NotificationAction" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { INotificationAction } from "sap/ui/webc/fiori/library"; - - import { ButtonDesign } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * The `sap.ui.webc.fiori.NotificationAction` represents an abstract action, used in the `sap.ui.webc.fiori.NotificationListItem` - * and the `sap.ui.webc.fiori.NotificationListGroupItem` items. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class NotificationAction - extends WebComponent - implements INotificationAction - { - __implements__sap_ui_webc_fiori_INotificationAction: boolean; - /** - * Constructor for a new `NotificationAction`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $NotificationActionSettings - ); - /** - * Constructor for a new `NotificationAction`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $NotificationActionSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.NotificationAction with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.NotificationAction. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.NotificationAction`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationAction` itself. - * - * Fired, when the action is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: NotificationAction$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationAction` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.NotificationAction`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationAction` itself. - * - * Fired, when the action is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: NotificationAction$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationAction` - * itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.fiori.NotificationAction`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: NotificationAction$ClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: NotificationAction$ClickEventParameters - ): this; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the action design. - * - * Default value is `Transparent`. - * - * - * @returns Value of property `design` - */ - getDesign(): ButtonDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the `sap.ui.webc.fiori.NotificationAction`. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the action design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Transparent`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: ButtonDesign | keyof typeof ButtonDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the `sap.ui.webc.fiori.NotificationAction`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the NotificationAction constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $NotificationActionSettings extends $WebComponentSettings { - /** - * Defines the action design. - */ - design?: - | (ButtonDesign | keyof typeof ButtonDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the text of the `sap.ui.webc.fiori.NotificationAction`. - */ - text?: string | PropertyBindingInfo; - - /** - * Fired, when the action is pressed. - */ - click?: (oEvent: NotificationAction$ClickEvent) => void; - } - - /** - * Parameters of the NotificationAction#click event. - */ - export interface NotificationAction$ClickEventParameters { - /** - * DOM ref of the clicked element - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the NotificationAction#click event. - */ - export type NotificationAction$ClickEvent = Event< - NotificationAction$ClickEventParameters, - NotificationAction - >; -} - -declare module "sap/ui/webc/fiori/NotificationListGroupItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IListItem, Priority } from "sap/ui/webc/main/library"; - - import { - INotificationAction, - INotificationListItem, - } from "sap/ui/webc/fiori/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.fiori.NotificationListGroupItem` is a special type of list item, that unlike - * others can group items within self, usually `sap.ui.webc.fiori.NotificationListItem` items. - * - * - * The component consists of: - * - `Toggle` button to expand and collapse the group - * - `Priority` icon to display the priority of the group - * - `TitleText` to entitle the group - * - Custom actions - with the use of `sap.ui.webc.fiori.NotificationAction` - * - Items of the group - * - * Usage: The component can be used in a standard `sap.ui.webc.main.List`. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.fiori.NotificationListGroupItem` exposes the following CSS Shadow Parts: - * - title-text - Used to style the titleText of the notification list group item - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class NotificationListGroupItem - extends WebComponent - implements IListItem - { - __implements__sap_ui_webc_main_IListItem: boolean; - /** - * Constructor for a new `NotificationListGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $NotificationListGroupItemSettings - ); - /** - * Constructor for a new `NotificationListGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $NotificationListGroupItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.NotificationListGroupItem with name `sClassName` and - * enriches it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.NotificationListGroupItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some action to the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAction( - /** - * The action to add; if empty, nothing is inserted - */ - oAction: INotificationAction - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: INotificationListItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.fiori.NotificationListGroupItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationListGroupItem` itself. - * - * Fired when the `Close` button is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: NotificationListGroupItem$CloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationListGroupItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.fiori.NotificationListGroupItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationListGroupItem` itself. - * - * Fired when the `Close` button is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: NotificationListGroupItem$CloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationListGroupItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:toggle toggle} event of this `sap.ui.webc.fiori.NotificationListGroupItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationListGroupItem` itself. - * - * Fired when the `sap.ui.webc.fiori.NotificationListGroupItem` is expanded/collapsed by user interaction. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachToggle( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationListGroupItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:toggle toggle} event of this `sap.ui.webc.fiori.NotificationListGroupItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationListGroupItem` itself. - * - * Fired when the `sap.ui.webc.fiori.NotificationListGroupItem` is expanded/collapsed by user interaction. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachToggle( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationListGroupItem` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the actions in the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyActions(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:close close} event of this `sap.ui.webc.fiori.NotificationListGroupItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: NotificationListGroupItem$CloseEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:toggle toggle} event of this `sap.ui.webc.fiori.NotificationListGroupItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachToggle( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:close close} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClose( - /** - * Parameters to pass along with the event - */ - mParameters?: NotificationListGroupItem$CloseEventParameters - ): this; - /** - * Fires event {@link #event:toggle toggle} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireToggle( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets content of aggregation {@link #getActions actions}. - * - * Defines the actions, displayed in the top-right area. - * - * **Note:** use the `sap.ui.webc.fiori.NotificationAction` component. - */ - getActions(): INotificationAction[]; - /** - * Gets current value of property {@link #getBusy busy}. - * - * Defines if a busy indicator would be displayed over the item. - * - * Default value is `false`. - * - * - * @returns Value of property `busy` - */ - getBusy(): boolean; - /** - * Gets current value of property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * Default value is `1000`. - * - * - * @returns Value of property `busyDelay` - */ - getBusyDelay(): int; - /** - * Gets current value of property {@link #getCollapsed collapsed}. - * - * Defines if the group is collapsed or expanded. - * - * Default value is `false`. - * - * - * @returns Value of property `collapsed` - */ - getCollapsed(): boolean; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the `sap.ui.webc.fiori.NotificationListGroupItem`, usually `sap.ui.webc.fiori.NotificationListItem` - * items. - */ - getItems(): INotificationListItem[]; - /** - * Gets current value of property {@link #getPriority priority}. - * - * Defines the `priority` of the item. - * - * Default value is `None`. - * - * - * @returns Value of property `priority` - */ - getPriority(): Priority; - /** - * Gets current value of property {@link #getRead read}. - * - * Defines if the `notification` is new or has been already read. - * - * **Note:** if set to `false` the `titleText` has bold font, if set to true - it has a normal font. - * - * Default value is `false`. - * - * - * @returns Value of property `read` - */ - getRead(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getShowClose showClose}. - * - * Defines if the `close` button would be displayed. - * - * Default value is `false`. - * - * - * @returns Value of property `showClose` - */ - getShowClose(): boolean; - /** - * Gets current value of property {@link #getShowCounter showCounter}. - * - * Defines if the items `counter` would be displayed. - * - * Default value is `false`. - * - * - * @returns Value of property `showCounter` - */ - getShowCounter(): boolean; - /** - * Gets current value of property {@link #getTitleText titleText}. - * - * Defines the `titleText` of the item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `titleText` - */ - getTitleText(): string; - /** - * Checks for the provided `sap.ui.webc.fiori.INotificationAction` in the aggregation {@link #getActions actions}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfAction( - /** - * The action whose index is looked for - */ - oAction: INotificationAction - ): int; - /** - * Checks for the provided `sap.ui.webc.fiori.INotificationListItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: INotificationListItem - ): int; - /** - * Inserts a action into the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertAction( - /** - * The action to insert; if empty, nothing is inserted - */ - oAction: INotificationAction, - /** - * The `0`-based index the action should be inserted at; for a negative value of `iIndex`, the action is - * inserted at position 0; for a value greater than the current size of the aggregation, the action is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: INotificationListItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes a action from the aggregation {@link #getActions actions}. - * - * - * @returns The removed action or `null` - */ - removeAction( - /** - * The action to remove or its index or id - */ - vAction: int | string | INotificationAction - ): INotificationAction | null; - /** - * Removes all the controls from the aggregation {@link #getActions actions}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllActions(): INotificationAction[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): INotificationListItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | INotificationListItem - ): INotificationListItem | null; - /** - * Sets a new value for property {@link #getBusy busy}. - * - * Defines if a busy indicator would be displayed over the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusy( - /** - * New value for property `busy` - */ - bBusy?: boolean - ): this; - /** - * Sets a new value for property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusyDelay( - /** - * New value for property `busyDelay` - */ - iBusyDelay?: int - ): this; - /** - * Sets a new value for property {@link #getCollapsed collapsed}. - * - * Defines if the group is collapsed or expanded. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setCollapsed( - /** - * New value for property `collapsed` - */ - bCollapsed?: boolean - ): this; - /** - * Sets a new value for property {@link #getPriority priority}. - * - * Defines the `priority` of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPriority( - /** - * New value for property `priority` - */ - sPriority?: Priority | keyof typeof Priority - ): this; - /** - * Sets a new value for property {@link #getRead read}. - * - * Defines if the `notification` is new or has been already read. - * - * **Note:** if set to `false` the `titleText` has bold font, if set to true - it has a normal font. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRead( - /** - * New value for property `read` - */ - bRead?: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowClose showClose}. - * - * Defines if the `close` button would be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowClose( - /** - * New value for property `showClose` - */ - bShowClose?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowCounter showCounter}. - * - * Defines if the items `counter` would be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowCounter( - /** - * New value for property `showCounter` - */ - bShowCounter?: boolean - ): this; - /** - * Sets a new value for property {@link #getTitleText titleText}. - * - * Defines the `titleText` of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitleText( - /** - * New value for property `titleText` - */ - sTitleText?: string - ): this; - } - /** - * Describes the settings that can be provided to the NotificationListGroupItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $NotificationListGroupItemSettings - extends $WebComponentSettings { - /** - * Defines if a busy indicator would be displayed over the item. - */ - busy?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - */ - busyDelay?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the group is collapsed or expanded. - */ - collapsed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `priority` of the item. - */ - priority?: - | (Priority | keyof typeof Priority) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines if the `notification` is new or has been already read. - * - * **Note:** if set to `false` the `titleText` has bold font, if set to true - it has a normal font. - */ - read?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the `close` button would be displayed. - */ - showClose?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the items `counter` would be displayed. - */ - showCounter?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `titleText` of the item. - */ - titleText?: string | PropertyBindingInfo; - - /** - * Defines the actions, displayed in the top-right area. - * - * **Note:** use the `sap.ui.webc.fiori.NotificationAction` component. - */ - actions?: - | INotificationAction[] - | INotificationAction - | AggregationBindingInfo - | `{${string}}`; - - /** - * Defines the items of the `sap.ui.webc.fiori.NotificationListGroupItem`, usually `sap.ui.webc.fiori.NotificationListItem` - * items. - */ - items?: - | INotificationListItem[] - | INotificationListItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the `Close` button is pressed. - */ - close?: (oEvent: NotificationListGroupItem$CloseEvent) => void; - - /** - * Fired when the `sap.ui.webc.fiori.NotificationListGroupItem` is expanded/collapsed by user interaction. - */ - toggle?: (oEvent: Event) => void; - } - - /** - * Parameters of the NotificationListGroupItem#close event. - */ - export interface NotificationListGroupItem$CloseEventParameters { - /** - * the closed item. - */ - item?: HTMLElement; - } - - /** - * Event object of the NotificationListGroupItem#close event. - */ - export type NotificationListGroupItem$CloseEvent = Event< - NotificationListGroupItem$CloseEventParameters, - NotificationListGroupItem - >; - - /** - * Parameters of the NotificationListGroupItem#toggle event. - */ - export interface NotificationListGroupItem$ToggleEventParameters {} - - /** - * Event object of the NotificationListGroupItem#toggle event. - */ - export type NotificationListGroupItem$ToggleEvent = Event< - NotificationListGroupItem$ToggleEventParameters, - NotificationListGroupItem - >; -} - -declare module "sap/ui/webc/fiori/NotificationListItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - INotificationListItem, - INotificationAction, - } from "sap/ui/webc/fiori/library"; - - import { - IListItem, - IAvatar, - Priority, - WrappingType, - } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The `sap.ui.webc.fiori.NotificationListItem` is a type of list item, meant to display notifications. - * - * - * - * The component has a rich set of various properties that allows the user to set `avatar`, `titleText`, - * descriptive `content` and `footnotes` to fully describe a notification. - * - * - * The user can: - * - display a `Close` button - * - can control whether the `titleText` and `description` should wrap or truncate and display a `ShowMore` - * button to switch between less and more information - * - add custom actions by using the `sap.ui.webc.fiori.NotificationAction` component - * - * Usage: The component can be used in a standard `sap.ui.webc.main.List`. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.fiori.NotificationListItem` exposes the following CSS Shadow Parts: - * - title-text - Used to style the titleText of the notification list item - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class NotificationListItem - extends WebComponent - implements INotificationListItem, IListItem - { - __implements__sap_ui_webc_fiori_INotificationListItem: boolean; - __implements__sap_ui_webc_main_IListItem: boolean; - /** - * Constructor for a new `NotificationListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $NotificationListItemSettings - ); - /** - * Constructor for a new `NotificationListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $NotificationListItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.NotificationListItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.NotificationListItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some action to the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAction( - /** - * The action to add; if empty, nothing is inserted - */ - oAction: INotificationAction - ): this; - /** - * Adds some footnote to the aggregation {@link #getFootnotes footnotes}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addFootnote( - /** - * The footnote to add; if empty, nothing is inserted - */ - oFootnote: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.fiori.NotificationListItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationListItem` itself. - * - * Fired when the `Close` button is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: NotificationListItem$CloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationListItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.fiori.NotificationListItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.NotificationListItem` itself. - * - * Fired when the `Close` button is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: NotificationListItem$CloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.NotificationListItem` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the actions in the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyActions(): this; - /** - * Destroys the avatar in the aggregation {@link #getAvatar avatar}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyAvatar(): this; - /** - * Destroys all the footnotes in the aggregation {@link #getFootnotes footnotes}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyFootnotes(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:close close} event of this `sap.ui.webc.fiori.NotificationListItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: NotificationListItem$CloseEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:close close} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClose( - /** - * Parameters to pass along with the event - */ - mParameters?: NotificationListItem$CloseEventParameters - ): this; - /** - * Gets content of aggregation {@link #getActions actions}. - * - * Defines the actions, displayed in the top-right area. - * - * **Note:** use the `sap.ui.webc.fiori.NotificationAction` component. - */ - getActions(): INotificationAction[]; - /** - * Gets content of aggregation {@link #getAvatar avatar}. - * - * Defines the avatar, displayed in the `sap.ui.webc.fiori.NotificationListItem`. - * - * - * - * **Note:** Consider using the `sap.ui.webc.main.Avatar` to display icons, initials or images. - * **Note:**In order to be complaint with the UX guidlines and for best experience, we recommend using - * avatars with 2rem X 2rem in size (32px X 32px). In case you are using the `sap.ui.webc.main.Avatar` you - * can set its `size` property to `XS` to get the required size - ``. - */ - getAvatar(): IAvatar; - /** - * Gets current value of property {@link #getBusy busy}. - * - * Defines if a busy indicator would be displayed over the item. - * - * Default value is `false`. - * - * - * @returns Value of property `busy` - */ - getBusy(): boolean; - /** - * Gets current value of property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * Default value is `1000`. - * - * - * @returns Value of property `busyDelay` - */ - getBusyDelay(): int; - /** - * Gets current value of property {@link #getDescription description}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `description` - */ - getDescription(): string; - /** - * Gets content of aggregation {@link #getFootnotes footnotes}. - * - * Defines the elements, displayed in the footer of the of the component. - */ - getFootnotes(): Control[]; - /** - * Gets current value of property {@link #getPriority priority}. - * - * Defines the `priority` of the item. - * - * Default value is `None`. - * - * - * @returns Value of property `priority` - */ - getPriority(): Priority; - /** - * Gets current value of property {@link #getRead read}. - * - * Defines if the `notification` is new or has been already read. - * - * **Note:** if set to `false` the `titleText` has bold font, if set to true - it has a normal font. - * - * Default value is `false`. - * - * - * @returns Value of property `read` - */ - getRead(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getShowClose showClose}. - * - * Defines if the `close` button would be displayed. - * - * Default value is `false`. - * - * - * @returns Value of property `showClose` - */ - getShowClose(): boolean; - /** - * Gets current value of property {@link #getTitleText titleText}. - * - * Defines the `titleText` of the item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `titleText` - */ - getTitleText(): string; - /** - * Gets current value of property {@link #getWrappingType wrappingType}. - * - * Defines if the `titleText` and `description` should wrap, they truncate by default. - * - * - * - * **Note:** by default the `titleText` and `description`, and a `ShowMore/Less` button would be displayed. - * - * Default value is `None`. - * - * - * @returns Value of property `wrappingType` - */ - getWrappingType(): WrappingType; - /** - * Checks for the provided `sap.ui.webc.fiori.INotificationAction` in the aggregation {@link #getActions actions}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfAction( - /** - * The action whose index is looked for - */ - oAction: INotificationAction - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getFootnotes footnotes}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfFootnote( - /** - * The footnote whose index is looked for - */ - oFootnote: Control - ): int; - /** - * Inserts a action into the aggregation {@link #getActions actions}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertAction( - /** - * The action to insert; if empty, nothing is inserted - */ - oAction: INotificationAction, - /** - * The `0`-based index the action should be inserted at; for a negative value of `iIndex`, the action is - * inserted at position 0; for a value greater than the current size of the aggregation, the action is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a footnote into the aggregation {@link #getFootnotes footnotes}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertFootnote( - /** - * The footnote to insert; if empty, nothing is inserted - */ - oFootnote: Control, - /** - * The `0`-based index the footnote should be inserted at; for a negative value of `iIndex`, the footnote - * is inserted at position 0; for a value greater than the current size of the aggregation, the footnote - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes a action from the aggregation {@link #getActions actions}. - * - * - * @returns The removed action or `null` - */ - removeAction( - /** - * The action to remove or its index or id - */ - vAction: int | string | INotificationAction - ): INotificationAction | null; - /** - * Removes all the controls from the aggregation {@link #getActions actions}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllActions(): INotificationAction[]; - /** - * Removes all the controls from the aggregation {@link #getFootnotes footnotes}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllFootnotes(): Control[]; - /** - * Removes a footnote from the aggregation {@link #getFootnotes footnotes}. - * - * - * @returns The removed footnote or `null` - */ - removeFootnote( - /** - * The footnote to remove or its index or id - */ - vFootnote: int | string | Control - ): Control | null; - /** - * Sets the aggregated {@link #getAvatar avatar}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAvatar( - /** - * The avatar to set - */ - oAvatar: IAvatar - ): this; - /** - * Sets a new value for property {@link #getBusy busy}. - * - * Defines if a busy indicator would be displayed over the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusy( - /** - * New value for property `busy` - */ - bBusy?: boolean - ): this; - /** - * Sets a new value for property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusyDelay( - /** - * New value for property `busyDelay` - */ - iBusyDelay?: int - ): this; - /** - * Sets a new value for property {@link #getDescription description}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDescription( - /** - * New value for property `description` - */ - sDescription?: string - ): this; - /** - * Sets a new value for property {@link #getPriority priority}. - * - * Defines the `priority` of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPriority( - /** - * New value for property `priority` - */ - sPriority?: Priority | keyof typeof Priority - ): this; - /** - * Sets a new value for property {@link #getRead read}. - * - * Defines if the `notification` is new or has been already read. - * - * **Note:** if set to `false` the `titleText` has bold font, if set to true - it has a normal font. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRead( - /** - * New value for property `read` - */ - bRead?: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowClose showClose}. - * - * Defines if the `close` button would be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowClose( - /** - * New value for property `showClose` - */ - bShowClose?: boolean - ): this; - /** - * Sets a new value for property {@link #getTitleText titleText}. - * - * Defines the `titleText` of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitleText( - /** - * New value for property `titleText` - */ - sTitleText?: string - ): this; - /** - * Sets a new value for property {@link #getWrappingType wrappingType}. - * - * Defines if the `titleText` and `description` should wrap, they truncate by default. - * - * - * - * **Note:** by default the `titleText` and `description`, and a `ShowMore/Less` button would be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWrappingType( - /** - * New value for property `wrappingType` - */ - sWrappingType?: WrappingType | keyof typeof WrappingType - ): this; - } - /** - * Describes the settings that can be provided to the NotificationListItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $NotificationListItemSettings extends $WebComponentSettings { - /** - * Defines if a busy indicator would be displayed over the item. - */ - busy?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - */ - busyDelay?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - description?: string | PropertyBindingInfo; - - /** - * Defines the `priority` of the item. - */ - priority?: - | (Priority | keyof typeof Priority) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines if the `notification` is new or has been already read. - * - * **Note:** if set to `false` the `titleText` has bold font, if set to true - it has a normal font. - */ - read?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the `close` button would be displayed. - */ - showClose?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `titleText` of the item. - */ - titleText?: string | PropertyBindingInfo; - - /** - * Defines if the `titleText` and `description` should wrap, they truncate by default. - * - * - * - * **Note:** by default the `titleText` and `description`, and a `ShowMore/Less` button would be displayed. - */ - wrappingType?: - | (WrappingType | keyof typeof WrappingType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the actions, displayed in the top-right area. - * - * **Note:** use the `sap.ui.webc.fiori.NotificationAction` component. - */ - actions?: - | INotificationAction[] - | INotificationAction - | AggregationBindingInfo - | `{${string}}`; - - /** - * Defines the avatar, displayed in the `sap.ui.webc.fiori.NotificationListItem`. - * - * - * - * **Note:** Consider using the `sap.ui.webc.main.Avatar` to display icons, initials or images. - * **Note:**In order to be complaint with the UX guidlines and for best experience, we recommend using - * avatars with 2rem X 2rem in size (32px X 32px). In case you are using the `sap.ui.webc.main.Avatar` you - * can set its `size` property to `XS` to get the required size - ``. - */ - avatar?: IAvatar; - - /** - * Defines the elements, displayed in the footer of the of the component. - */ - footnotes?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the `Close` button is pressed. - */ - close?: (oEvent: NotificationListItem$CloseEvent) => void; - } - - /** - * Parameters of the NotificationListItem#close event. - */ - export interface NotificationListItem$CloseEventParameters { - /** - * the closed item. - */ - item?: HTMLElement; - } - - /** - * Event object of the NotificationListItem#close event. - */ - export type NotificationListItem$CloseEvent = Event< - NotificationListItem$CloseEventParameters, - NotificationListItem - >; -} - -declare module "sap/ui/webc/fiori/Page" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Control from "sap/ui/core/Control"; - - import { PageBackgroundDesign, IBar } from "sap/ui/webc/fiori/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.Page` is a container component that holds one whole screen of an application. - * The page has three distinct areas that can hold content - a header, content area and a footer. Structure: - * Header: The top most area of the page is occupied by the header. The standard header includes a navigation - * button and a title. Content: The content occupies the main part of the page. Only the content area is - * scrollable by default. This can be prevented by setting `enableScrolling` to `false`. Footer: The footer - * is optional and occupies the fixed bottom part of the page. Alternatively, the footer can be floating - * above the bottom part of the content. This is enabled with the `floatingFooter` property. - * - * **Note:** `sap.ui.webc.fiori.Page` occipues the whole available space of its parent. In order to achieve - * the intended design you have to make sure that there is enough space for the `sap.ui.webc.fiori.Page` - * to be rendered. **Note:** In order for the `sap.ui.webc.fiori.Page` to be displayed, the parent element - * should have fixed height. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.fiori.Page` exposes the following CSS Shadow Parts: - * - content - Used to style the content section of the component - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Page extends WebComponent { - /** - * Constructor for a new `Page`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $PageSettings - ); - /** - * Constructor for a new `Page`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $PageSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.Page with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.Page. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys the footer in the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyFooter(): this; - /** - * Destroys the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Gets current value of property {@link #getBackgroundDesign backgroundDesign}. - * - * Defines the background color of the `sap.ui.webc.fiori.Page`. - * - * **Note:** When a ui5-list is placed inside the page, we recommend using “List” to ensure better color - * contrast. - * - * - * - * Default value is `Solid`. - * - * - * @returns Value of property `backgroundDesign` - */ - getBackgroundDesign(): PageBackgroundDesign; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content HTML Element. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getDisableScrolling disableScrolling}. - * - * Disables vertical scrolling of page content. If set to true, there will be no vertical scrolling at all. - * - * Default value is `false`. - * - * - * @returns Value of property `disableScrolling` - */ - getDisableScrolling(): boolean; - /** - * Gets current value of property {@link #getFloatingFooter floatingFooter}. - * - * Defines if the footer should float over the content. - * - * **Note:** When set to true the footer floats over the content with a slight offset from the bottom, - * otherwise it is fixed at the very bottom of the page. - * - * Default value is `true`. - * - * - * @returns Value of property `floatingFooter` - */ - getFloatingFooter(): boolean; - /** - * Gets content of aggregation {@link #getFooter footer}. - * - * Defines the footer HTML Element. - */ - getFooter(): IBar; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the header HTML Element. - */ - getHeader(): IBar; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getHideFooter hideFooter}. - * - * Defines the footer visibility. - * - * Default value is `false`. - * - * - * @returns Value of property `hideFooter` - */ - getHideFooter(): boolean; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getBackgroundDesign backgroundDesign}. - * - * Defines the background color of the `sap.ui.webc.fiori.Page`. - * - * **Note:** When a ui5-list is placed inside the page, we recommend using “List” to ensure better color - * contrast. - * - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Solid`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBackgroundDesign( - /** - * New value for property `backgroundDesign` - */ - sBackgroundDesign?: - | PageBackgroundDesign - | keyof typeof PageBackgroundDesign - ): this; - /** - * Sets a new value for property {@link #getDisableScrolling disableScrolling}. - * - * Disables vertical scrolling of page content. If set to true, there will be no vertical scrolling at all. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDisableScrolling( - /** - * New value for property `disableScrolling` - */ - bDisableScrolling?: boolean - ): this; - /** - * Sets a new value for property {@link #getFloatingFooter floatingFooter}. - * - * Defines if the footer should float over the content. - * - * **Note:** When set to true the footer floats over the content with a slight offset from the bottom, - * otherwise it is fixed at the very bottom of the page. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFloatingFooter( - /** - * New value for property `floatingFooter` - */ - bFloatingFooter?: boolean - ): this; - /** - * Sets the aggregated {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFooter( - /** - * The footer to set - */ - oFooter: IBar - ): this; - /** - * Sets the aggregated {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeader( - /** - * The header to set - */ - oHeader: IBar - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getHideFooter hideFooter}. - * - * Defines the footer visibility. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideFooter( - /** - * New value for property `hideFooter` - */ - bHideFooter?: boolean - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Page constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $PageSettings extends $WebComponentSettings { - /** - * Defines the background color of the `sap.ui.webc.fiori.Page`. - * - * **Note:** When a ui5-list is placed inside the page, we recommend using “List” to ensure better color - * contrast. - */ - backgroundDesign?: - | (PageBackgroundDesign | keyof typeof PageBackgroundDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Disables vertical scrolling of page content. If set to true, there will be no vertical scrolling at all. - */ - disableScrolling?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the footer should float over the content. - * - * **Note:** When set to true the footer floats over the content with a slight offset from the bottom, - * otherwise it is fixed at the very bottom of the page. - */ - floatingFooter?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the footer visibility. - */ - hideFooter?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content HTML Element. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the footer HTML Element. - */ - footer?: IBar; - - /** - * Defines the header HTML Element. - */ - header?: IBar; - } -} - -declare module "sap/ui/webc/fiori/ProductSwitch" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IProductSwitchItem } from "sap/ui/webc/fiori/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { AggregationBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.ProductSwitch` is an SAP Fiori specific web component that is used in `sap.ui.webc.fiori.ShellBar` - * and allows the user to easily switch between products. - * - * - * - * Keyboard Handling: The `sap.ui.webc.fiori.ProductSwitch` provides advanced keyboard handling. When focused, - * the user can use the following keyboard shortcuts in order to perform a navigation: - * - * - * - * - [TAB] - Move focus to the next interactive element after the `sap.ui.webc.fiori.ProductSwitch` - * - [UP/DOWN] - Navigates up and down the items - * - [LEFT/RIGHT] - Navigates left and right the items - * - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ProductSwitch extends WebComponent { - /** - * Constructor for a new `ProductSwitch`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ProductSwitchSettings - ); - /** - * Constructor for a new `ProductSwitch`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ProductSwitchSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.ProductSwitch with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.ProductSwitch. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IProductSwitchItem - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the `sap.ui.webc.fiori.ProductSwitch`. - */ - getItems(): IProductSwitchItem[]; - /** - * Checks for the provided `sap.ui.webc.fiori.IProductSwitchItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IProductSwitchItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IProductSwitchItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IProductSwitchItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IProductSwitchItem - ): IProductSwitchItem | null; - } - /** - * Describes the settings that can be provided to the ProductSwitch constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ProductSwitchSettings extends $WebComponentSettings { - /** - * Defines the items of the `sap.ui.webc.fiori.ProductSwitch`. - */ - items?: - | IProductSwitchItem[] - | IProductSwitchItem - | AggregationBindingInfo - | `{${string}}`; - } -} - -declare module "sap/ui/webc/fiori/ProductSwitchItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IProductSwitchItem } from "sap/ui/webc/fiori/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.fiori.ProductSwitchItem` web component represents the items displayed in the - * `sap.ui.webc.fiori.ProductSwitch` web component. - * - * **Note:** `sap.ui.webc.fiori.ProductSwitchItem` is not supported when used outside of `sap.ui.webc.fiori.ProductSwitch`. - * - * - * - * - * Keyboard Handling: The `sap.ui.webc.fiori.ProductSwitch` provides advanced keyboard handling. When focused, - * the user can use the following keyboard shortcuts in order to perform a navigation: - * - * - * - * - [SPACE/ENTER/RETURN] - Trigger `ui5-click` event - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ProductSwitchItem - extends WebComponent - implements IProductSwitchItem - { - __implements__sap_ui_webc_fiori_IProductSwitchItem: boolean; - /** - * Constructor for a new `ProductSwitchItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ProductSwitchItemSettings - ); - /** - * Constructor for a new `ProductSwitchItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ProductSwitchItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.ProductSwitchItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.ProductSwitchItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.ProductSwitchItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ProductSwitchItem` itself. - * - * Fired when the `sap.ui.webc.fiori.ProductSwitchItem` is activated either with a click/tap or by using - * the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ProductSwitchItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.ProductSwitchItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ProductSwitchItem` itself. - * - * Fired when the `sap.ui.webc.fiori.ProductSwitchItem` is activated either with a click/tap or by using - * the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ProductSwitchItem` - * itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.fiori.ProductSwitchItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon to be displayed as a graphical element within the component. - * - * Example: - * - * ```javascript - * ui5-product-switch-item icon="palette"``` - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `subtitleText` - */ - getSubtitleText(): string; - /** - * Gets current value of property {@link #getTarget target}. - * - * Defines a target where the `targetSrc` content must be open. - * - * Available options are: - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * - * @returns Value of property `target` - */ - getTarget(): string; - /** - * Gets current value of property {@link #getTargetSrc targetSrc}. - * - * Defines the component target URI. Supports standard hyperlink behavior. - * - * Default value is `empty string`. - * - * - * @returns Value of property `targetSrc` - */ - getTargetSrc(): string; - /** - * Gets current value of property {@link #getTitleText titleText}. - * - * Defines the title of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `titleText` - */ - getTitleText(): string; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon to be displayed as a graphical element within the component. - * - * Example: - * - * ```javascript - * ui5-product-switch-item icon="palette"``` - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSubtitleText( - /** - * New value for property `subtitleText` - */ - sSubtitleText?: string - ): this; - /** - * Sets a new value for property {@link #getTarget target}. - * - * Defines a target where the `targetSrc` content must be open. - * - * Available options are: - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTarget( - /** - * New value for property `target` - */ - sTarget: string - ): this; - /** - * Sets a new value for property {@link #getTargetSrc targetSrc}. - * - * Defines the component target URI. Supports standard hyperlink behavior. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTargetSrc( - /** - * New value for property `targetSrc` - */ - sTargetSrc?: string - ): this; - /** - * Sets a new value for property {@link #getTitleText titleText}. - * - * Defines the title of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitleText( - /** - * New value for property `titleText` - */ - sTitleText?: string - ): this; - } - /** - * Describes the settings that can be provided to the ProductSwitchItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ProductSwitchItemSettings extends $WebComponentSettings { - /** - * Defines the icon to be displayed as a graphical element within the component. - * - * Example: - * - * ```javascript - * ui5-product-switch-item icon="palette"``` - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the subtitle of the component. - */ - subtitleText?: string | PropertyBindingInfo; - - /** - * Defines a target where the `targetSrc` content must be open. - * - * Available options are: - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - */ - target?: string | PropertyBindingInfo; - - /** - * Defines the component target URI. Supports standard hyperlink behavior. - */ - targetSrc?: string | PropertyBindingInfo; - - /** - * Defines the title of the component. - */ - titleText?: string | PropertyBindingInfo; - - /** - * Fired when the `sap.ui.webc.fiori.ProductSwitchItem` is activated either with a click/tap or by using - * the Enter or Space key. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the ProductSwitchItem#click event. - */ - export interface ProductSwitchItem$ClickEventParameters {} - - /** - * Event object of the ProductSwitchItem#click event. - */ - export type ProductSwitchItem$ClickEvent = Event< - ProductSwitchItem$ClickEventParameters, - ProductSwitchItem - >; -} - -declare module "sap/ui/webc/fiori/ShellBar" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IShellBarItem } from "sap/ui/webc/fiori/library"; - - import { - IListItem, - IAvatar, - IInput, - IButton, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.ShellBar` is meant to serve as an application header and includes numerous built-in - * features, such as: logo, profile image/icon, title, search field, notifications and so on. - * - * - * - * Stable DOM Refs: - * - * You can use the following stable DOM refs for the `sap.ui.webc.fiori.ShellBar`: - * - logo - * - copilot - * - notifications - * - overflow - * - profile - * - product-switch - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.fiori.ShellBar` exposes the following CSS Shadow Parts: - * - root - Used to style the outermost wrapper of the `sap.ui.webc.fiori.ShellBar` - * - * Keyboard Handling: - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ShellBar extends WebComponent { - /** - * Constructor for a new `ShellBar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ShellBarSettings - ); - /** - * Constructor for a new `ShellBar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ShellBarSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.ShellBar with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.ShellBar. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IShellBarItem - ): this; - /** - * Adds some menuItem to the aggregation {@link #getMenuItems menuItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addMenuItem( - /** - * The menuItem to add; if empty, nothing is inserted - */ - oMenuItem: IListItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:coPilotClick coPilotClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the co pilot is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachCoPilotClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$CoPilotClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:coPilotClick coPilotClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the co pilot is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachCoPilotClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$CoPilotClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:logoClick logoClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the logo is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLogoClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$LogoClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:logoClick logoClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the logo is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLogoClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$LogoClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:menuItemClick menuItemClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when a menu item is activated **Note:** You can prevent closing of overflow popover by calling - * `event.preventDefault()`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachMenuItemClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$MenuItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:menuItemClick menuItemClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when a menu item is activated **Note:** You can prevent closing of overflow popover by calling - * `event.preventDefault()`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachMenuItemClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$MenuItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:notificationsClick notificationsClick} event - * of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the notification icon is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachNotificationsClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$NotificationsClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:notificationsClick notificationsClick} event - * of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the notification icon is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachNotificationsClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$NotificationsClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:productSwitchClick productSwitchClick} event - * of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the product switch icon is activated. **Note:** You can prevent closing of overflow popover - * by calling `event.preventDefault()`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachProductSwitchClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$ProductSwitchClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:productSwitchClick productSwitchClick} event - * of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the product switch icon is activated. **Note:** You can prevent closing of overflow popover - * by calling `event.preventDefault()`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachProductSwitchClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$ProductSwitchClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:profileClick profileClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the profile slot is present. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachProfileClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$ProfileClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:profileClick profileClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBar` itself. - * - * Fired, when the profile slot is present. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachProfileClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBar$ProfileClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBar` itself - */ - oListener?: object - ): this; - /** - * Closes the overflow area. Useful to manually close the overflow after having suppressed automatic closing - * with preventDefault() of ShellbarItem's press event - */ - closeOverflow(): void; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Destroys the logo in the aggregation {@link #getLogo logo}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyLogo(): this; - /** - * Destroys all the menuItems in the aggregation {@link #getMenuItems menuItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyMenuItems(): this; - /** - * Destroys the profile in the aggregation {@link #getProfile profile}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyProfile(): this; - /** - * Destroys the searchField in the aggregation {@link #getSearchField searchField}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySearchField(): this; - /** - * Destroys the startButton in the aggregation {@link #getStartButton startButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyStartButton(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:coPilotClick coPilotClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachCoPilotClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ShellBar$CoPilotClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:logoClick logoClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachLogoClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ShellBar$LogoClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:menuItemClick menuItemClick} event of this - * `sap.ui.webc.fiori.ShellBar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachMenuItemClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ShellBar$MenuItemClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:notificationsClick notificationsClick} event - * of this `sap.ui.webc.fiori.ShellBar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachNotificationsClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ShellBar$NotificationsClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:productSwitchClick productSwitchClick} event - * of this `sap.ui.webc.fiori.ShellBar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachProductSwitchClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ShellBar$ProductSwitchClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:profileClick profileClick} event of this `sap.ui.webc.fiori.ShellBar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachProfileClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ShellBar$ProfileClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:coPilotClick coPilotClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireCoPilotClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ShellBar$CoPilotClickEventParameters - ): this; - /** - * Fires event {@link #event:logoClick logoClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireLogoClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ShellBar$LogoClickEventParameters - ): this; - /** - * Fires event {@link #event:menuItemClick menuItemClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireMenuItemClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ShellBar$MenuItemClickEventParameters - ): this; - /** - * Fires event {@link #event:notificationsClick notificationsClick} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireNotificationsClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ShellBar$NotificationsClickEventParameters - ): boolean; - /** - * Fires event {@link #event:productSwitchClick productSwitchClick} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireProductSwitchClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ShellBar$ProductSwitchClickEventParameters - ): boolean; - /** - * Fires event {@link #event:profileClick profileClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireProfileClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ShellBar$ProfileClickEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the anchor element, or another grouping element it controls, is currently - * expanded or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the anchor element. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibilityRoles accessibilityRoles}. - * - * An object of strings that defines additional accessibility roles for further customization. - * - * It supports the following fields: - `logoRole`: the accessibility role for the `logo` - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityRoles` - */ - getAccessibilityRoles(): object; - /** - * Gets current value of property {@link #getAccessibilityTexts accessibilityTexts}. - * - * An object of strings that defines several additional accessibility texts for even further customization. - * - * It supports the following fields: - `profileButtonTitle`: defines the tooltip for the profile button - * - `logoTitle`: defines the tooltip for the logo - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityTexts` - */ - getAccessibilityTexts(): object; - /** - * Returns the `copilot` DOM ref. - */ - getCopilotDomRef(): void; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the `sap.ui.webc.fiori.ShellBar` aditional items. - * - * **Note:** You can use the . - */ - getItems(): IShellBarItem[]; - /** - * Gets content of aggregation {@link #getLogo logo}. - * - * Defines the logo of the `sap.ui.webc.fiori.ShellBar`. For example, you can use `sap.ui.webc.main.Avatar` - * or `img` elements as logo. - */ - getLogo(): IAvatar; - /** - * Returns the `logo` DOM ref. - */ - getLogoDomRef(): void; - /** - * Gets content of aggregation {@link #getMenuItems menuItems}. - * - * Defines the items displayed in menu after a click on the primary title. - * - * **Note:** You can use the and its ancestors. - */ - getMenuItems(): IListItem[]; - /** - * Gets current value of property {@link #getNotificationsCount notificationsCount}. - * - * Defines the `notificationsCount`, displayed in the notification icon top-right corner. - * - * Default value is `empty string`. - * - * - * @returns Value of property `notificationsCount` - */ - getNotificationsCount(): string; - /** - * Returns the `notifications` icon DOM ref. - */ - getNotificationsDomRef(): void; - /** - * Returns the `overflow` icon DOM ref. - */ - getOverflowDomRef(): void; - /** - * Gets current value of property {@link #getPrimaryTitle primaryTitle}. - * - * Defines the `primaryTitle`. - * - * **Note:** The `primaryTitle` would be hidden on S screen size (less than approx. 700px). - * - * Default value is `empty string`. - * - * - * @returns Value of property `primaryTitle` - */ - getPrimaryTitle(): string; - /** - * Returns the `product-switch` icon DOM ref. - */ - getProductSwitchDomRef(): void; - /** - * Gets content of aggregation {@link #getProfile profile}. - * - * You can pass `sap.ui.webc.main.Avatar` to set the profile image/icon. If no profile slot is set - profile - * will be excluded from actions. - * - * Note: We recommend not using the `size` attribute of `sap.ui.webc.main.Avatar` because it should have - * specific size by design in the context of `sap.ui.webc.fiori.ShellBar` profile. - */ - getProfile(): IAvatar; - /** - * Returns the `profile` icon DOM ref. - */ - getProfileDomRef(): void; - /** - * Gets content of aggregation {@link #getSearchField searchField}. - * - * Defines the `sap.ui.webc.main.Input`, that will be used as a search field. - */ - getSearchField(): IInput; - /** - * Gets current value of property {@link #getSecondaryTitle secondaryTitle}. - * - * Defines the `secondaryTitle`. - * - * **Note:** The `secondaryTitle` would be hidden on S and M screen sizes (less than approx. 1300px). - * - * Default value is `empty string`. - * - * - * @returns Value of property `secondaryTitle` - */ - getSecondaryTitle(): string; - /** - * Gets current value of property {@link #getShowCoPilot showCoPilot}. - * - * Defines, if the product CoPilot icon would be displayed. - * **Note:** By default the co-pilot is displayed as static SVG. If you need an animated co-pilot, you - * can import the `"@ui5/webcomponents-fiori/dist/features/CoPilotAnimation.js"` module as add-on feature. - * - * Default value is `false`. - * - * - * @returns Value of property `showCoPilot` - */ - getShowCoPilot(): boolean; - /** - * Gets current value of property {@link #getShowNotifications showNotifications}. - * - * Defines, if the notification icon would be displayed. - * - * Default value is `false`. - * - * - * @returns Value of property `showNotifications` - */ - getShowNotifications(): boolean; - /** - * Gets current value of property {@link #getShowProductSwitch showProductSwitch}. - * - * Defines, if the product switch icon would be displayed. - * - * Default value is `false`. - * - * - * @returns Value of property `showProductSwitch` - */ - getShowProductSwitch(): boolean; - /** - * Gets current value of property {@link #getShowSearchField showSearchField}. - * - * Defines, if the Search Field would be displayed when there is a valid `searchField` slot. - * **Note:** By default the Search Field is not displayed. - * - * Default value is `false`. - * - * - * @returns Value of property `showSearchField` - */ - getShowSearchField(): boolean; - /** - * Gets content of aggregation {@link #getStartButton startButton}. - * - * Defines a `sap.ui.webc.main.Button` in the bar that will be placed in the beginning. We encourage this - * slot to be used for a back or home button. It gets overstyled to match ShellBar's styling. - */ - getStartButton(): IButton; - /** - * Checks for the provided `sap.ui.webc.fiori.IShellBarItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IShellBarItem - ): int; - /** - * Checks for the provided `sap.ui.webc.main.IListItem` in the aggregation {@link #getMenuItems menuItems}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfMenuItem( - /** - * The menuItem whose index is looked for - */ - oMenuItem: IListItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IShellBarItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Inserts a menuItem into the aggregation {@link #getMenuItems menuItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertMenuItem( - /** - * The menuItem to insert; if empty, nothing is inserted - */ - oMenuItem: IListItem, - /** - * The `0`-based index the menuItem should be inserted at; for a negative value of `iIndex`, the menuItem - * is inserted at position 0; for a value greater than the current size of the aggregation, the menuItem - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IShellBarItem[]; - /** - * Removes all the controls from the aggregation {@link #getMenuItems menuItems}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllMenuItems(): IListItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IShellBarItem - ): IShellBarItem | null; - /** - * Removes a menuItem from the aggregation {@link #getMenuItems menuItems}. - * - * - * @returns The removed menuItem or `null` - */ - removeMenuItem( - /** - * The menuItem to remove or its index or id - */ - vMenuItem: int | string | IListItem - ): IListItem | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the anchor element, or another grouping element it controls, is currently - * expanded or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the anchor element. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibilityRoles accessibilityRoles}. - * - * An object of strings that defines additional accessibility roles for further customization. - * - * It supports the following fields: - `logoRole`: the accessibility role for the `logo` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityRoles( - /** - * New value for property `accessibilityRoles` - */ - oAccessibilityRoles?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibilityTexts accessibilityTexts}. - * - * An object of strings that defines several additional accessibility texts for even further customization. - * - * It supports the following fields: - `profileButtonTitle`: defines the tooltip for the profile button - * - `logoTitle`: defines the tooltip for the logo - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityTexts( - /** - * New value for property `accessibilityTexts` - */ - oAccessibilityTexts?: object - ): this; - /** - * Sets the aggregated {@link #getLogo logo}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLogo( - /** - * The logo to set - */ - oLogo: IAvatar - ): this; - /** - * Sets a new value for property {@link #getNotificationsCount notificationsCount}. - * - * Defines the `notificationsCount`, displayed in the notification icon top-right corner. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNotificationsCount( - /** - * New value for property `notificationsCount` - */ - sNotificationsCount?: string - ): this; - /** - * Sets a new value for property {@link #getPrimaryTitle primaryTitle}. - * - * Defines the `primaryTitle`. - * - * **Note:** The `primaryTitle` would be hidden on S screen size (less than approx. 700px). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPrimaryTitle( - /** - * New value for property `primaryTitle` - */ - sPrimaryTitle?: string - ): this; - /** - * Sets the aggregated {@link #getProfile profile}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setProfile( - /** - * The profile to set - */ - oProfile: IAvatar - ): this; - /** - * Sets the aggregated {@link #getSearchField searchField}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSearchField( - /** - * The searchField to set - */ - oSearchField: IInput - ): this; - /** - * Sets a new value for property {@link #getSecondaryTitle secondaryTitle}. - * - * Defines the `secondaryTitle`. - * - * **Note:** The `secondaryTitle` would be hidden on S and M screen sizes (less than approx. 1300px). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSecondaryTitle( - /** - * New value for property `secondaryTitle` - */ - sSecondaryTitle?: string - ): this; - /** - * Sets a new value for property {@link #getShowCoPilot showCoPilot}. - * - * Defines, if the product CoPilot icon would be displayed. - * **Note:** By default the co-pilot is displayed as static SVG. If you need an animated co-pilot, you - * can import the `"@ui5/webcomponents-fiori/dist/features/CoPilotAnimation.js"` module as add-on feature. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowCoPilot( - /** - * New value for property `showCoPilot` - */ - bShowCoPilot?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowNotifications showNotifications}. - * - * Defines, if the notification icon would be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowNotifications( - /** - * New value for property `showNotifications` - */ - bShowNotifications?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowProductSwitch showProductSwitch}. - * - * Defines, if the product switch icon would be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowProductSwitch( - /** - * New value for property `showProductSwitch` - */ - bShowProductSwitch?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowSearchField showSearchField}. - * - * Defines, if the Search Field would be displayed when there is a valid `searchField` slot. - * **Note:** By default the Search Field is not displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowSearchField( - /** - * New value for property `showSearchField` - */ - bShowSearchField?: boolean - ): this; - /** - * Sets the aggregated {@link #getStartButton startButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStartButton( - /** - * The startButton to set - */ - oStartButton: IButton - ): this; - } - /** - * Describes the settings that can be provided to the ShellBar constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ShellBarSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the anchor element, or another grouping element it controls, is currently - * expanded or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the anchor element. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * An object of strings that defines additional accessibility roles for further customization. - * - * It supports the following fields: - `logoRole`: the accessibility role for the `logo` - */ - accessibilityRoles?: object | PropertyBindingInfo | `{${string}}`; - - /** - * An object of strings that defines several additional accessibility texts for even further customization. - * - * It supports the following fields: - `profileButtonTitle`: defines the tooltip for the profile button - * - `logoTitle`: defines the tooltip for the logo - */ - accessibilityTexts?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `notificationsCount`, displayed in the notification icon top-right corner. - */ - notificationsCount?: string | PropertyBindingInfo; - - /** - * Defines the `primaryTitle`. - * - * **Note:** The `primaryTitle` would be hidden on S screen size (less than approx. 700px). - */ - primaryTitle?: string | PropertyBindingInfo; - - /** - * Defines the `secondaryTitle`. - * - * **Note:** The `secondaryTitle` would be hidden on S and M screen sizes (less than approx. 1300px). - */ - secondaryTitle?: string | PropertyBindingInfo; - - /** - * Defines, if the product CoPilot icon would be displayed. - * **Note:** By default the co-pilot is displayed as static SVG. If you need an animated co-pilot, you - * can import the `"@ui5/webcomponents-fiori/dist/features/CoPilotAnimation.js"` module as add-on feature. - */ - showCoPilot?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines, if the notification icon would be displayed. - */ - showNotifications?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines, if the product switch icon would be displayed. - */ - showProductSwitch?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines, if the Search Field would be displayed when there is a valid `searchField` slot. - * **Note:** By default the Search Field is not displayed. - */ - showSearchField?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `sap.ui.webc.fiori.ShellBar` aditional items. - * - * **Note:** You can use the . - */ - items?: - | IShellBarItem[] - | IShellBarItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Defines the logo of the `sap.ui.webc.fiori.ShellBar`. For example, you can use `sap.ui.webc.main.Avatar` - * or `img` elements as logo. - */ - logo?: IAvatar; - - /** - * Defines the items displayed in menu after a click on the primary title. - * - * **Note:** You can use the and its ancestors. - */ - menuItems?: - | IListItem[] - | IListItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * You can pass `sap.ui.webc.main.Avatar` to set the profile image/icon. If no profile slot is set - profile - * will be excluded from actions. - * - * Note: We recommend not using the `size` attribute of `sap.ui.webc.main.Avatar` because it should have - * specific size by design in the context of `sap.ui.webc.fiori.ShellBar` profile. - */ - profile?: IAvatar; - - /** - * Defines the `sap.ui.webc.main.Input`, that will be used as a search field. - */ - searchField?: IInput; - - /** - * Defines a `sap.ui.webc.main.Button` in the bar that will be placed in the beginning. We encourage this - * slot to be used for a back or home button. It gets overstyled to match ShellBar's styling. - */ - startButton?: IButton; - - /** - * Fired, when the co pilot is activated. - */ - coPilotClick?: (oEvent: ShellBar$CoPilotClickEvent) => void; - - /** - * Fired, when the logo is activated. - */ - logoClick?: (oEvent: ShellBar$LogoClickEvent) => void; - - /** - * Fired, when a menu item is activated **Note:** You can prevent closing of overflow popover by calling - * `event.preventDefault()`. - */ - menuItemClick?: (oEvent: ShellBar$MenuItemClickEvent) => void; - - /** - * Fired, when the notification icon is activated. - */ - notificationsClick?: (oEvent: ShellBar$NotificationsClickEvent) => void; - - /** - * Fired, when the product switch icon is activated. **Note:** You can prevent closing of overflow popover - * by calling `event.preventDefault()`. - */ - productSwitchClick?: (oEvent: ShellBar$ProductSwitchClickEvent) => void; - - /** - * Fired, when the profile slot is present. - */ - profileClick?: (oEvent: ShellBar$ProfileClickEvent) => void; - } - - /** - * Parameters of the ShellBar#coPilotClick event. - */ - export interface ShellBar$CoPilotClickEventParameters { - /** - * dom ref of the activated element - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the ShellBar#coPilotClick event. - */ - export type ShellBar$CoPilotClickEvent = Event< - ShellBar$CoPilotClickEventParameters, - ShellBar - >; - - /** - * Parameters of the ShellBar#logoClick event. - */ - export interface ShellBar$LogoClickEventParameters { - /** - * dom ref of the activated element - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the ShellBar#logoClick event. - */ - export type ShellBar$LogoClickEvent = Event< - ShellBar$LogoClickEventParameters, - ShellBar - >; - - /** - * Parameters of the ShellBar#menuItemClick event. - */ - export interface ShellBar$MenuItemClickEventParameters { - /** - * DOM ref of the activated list item - */ - item?: HTMLElement; - } - - /** - * Event object of the ShellBar#menuItemClick event. - */ - export type ShellBar$MenuItemClickEvent = Event< - ShellBar$MenuItemClickEventParameters, - ShellBar - >; - - /** - * Parameters of the ShellBar#notificationsClick event. - */ - export interface ShellBar$NotificationsClickEventParameters { - /** - * dom ref of the activated element - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the ShellBar#notificationsClick event. - */ - export type ShellBar$NotificationsClickEvent = Event< - ShellBar$NotificationsClickEventParameters, - ShellBar - >; - - /** - * Parameters of the ShellBar#productSwitchClick event. - */ - export interface ShellBar$ProductSwitchClickEventParameters { - /** - * dom ref of the activated element - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the ShellBar#productSwitchClick event. - */ - export type ShellBar$ProductSwitchClickEvent = Event< - ShellBar$ProductSwitchClickEventParameters, - ShellBar - >; - - /** - * Parameters of the ShellBar#profileClick event. - */ - export interface ShellBar$ProfileClickEventParameters { - /** - * dom ref of the activated element - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the ShellBar#profileClick event. - */ - export type ShellBar$ProfileClickEvent = Event< - ShellBar$ProfileClickEventParameters, - ShellBar - >; -} - -declare module "sap/ui/webc/fiori/ShellBarItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IShellBarItem } from "sap/ui/webc/fiori/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ShellBarItem - extends WebComponent - implements IShellBarItem - { - __implements__sap_ui_webc_fiori_IShellBarItem: boolean; - /** - * Constructor for a new `ShellBarItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ShellBarItemSettings - ); - /** - * Constructor for a new `ShellBarItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ShellBarItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.ShellBarItem with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.ShellBarItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.ShellBarItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBarItem` itself. - * - * Fired, when the item is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBarItem$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBarItem` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.ShellBarItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ShellBarItem` itself. - * - * Fired, when the item is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ShellBarItem$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ShellBarItem` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.fiori.ShellBarItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ShellBarItem$ClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ShellBarItem$ClickEventParameters - ): boolean; - /** - * Gets current value of property {@link #getCount count}. - * - * Defines the count displayed in the top-right corner. - * - * Default value is `empty string`. - * - * - * @returns Value of property `count` - */ - getCount(): string; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the name of the item's icon. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the item text. - * - * **Note:** The text is only displayed inside the overflow popover list view. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getCount count}. - * - * Defines the count displayed in the top-right corner. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setCount( - /** - * New value for property `count` - */ - sCount?: string - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the name of the item's icon. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the item text. - * - * **Note:** The text is only displayed inside the overflow popover list view. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the ShellBarItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ShellBarItemSettings extends $WebComponentSettings { - /** - * Defines the count displayed in the top-right corner. - */ - count?: string | PropertyBindingInfo; - - /** - * Defines the name of the item's icon. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the item text. - * - * **Note:** The text is only displayed inside the overflow popover list view. - */ - text?: string | PropertyBindingInfo; - - /** - * Fired, when the item is pressed. - */ - click?: (oEvent: ShellBarItem$ClickEvent) => void; - } - - /** - * Parameters of the ShellBarItem#click event. - */ - export interface ShellBarItem$ClickEventParameters { - /** - * DOM ref of the clicked element - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the ShellBarItem#click event. - */ - export type ShellBarItem$ClickEvent = Event< - ShellBarItem$ClickEventParameters, - ShellBarItem - >; -} - -declare module "sap/ui/webc/fiori/SideNavigation" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - ISideNavigationItem, - ISideNavigationSubItem, - } from "sap/ui/webc/fiori/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `SideNavigation` is used as a standard menu in applications. It consists of three containers: header - * (top-aligned), main navigation section (top-aligned) and the secondary section (bottom-aligned). - * - * - The header is meant for displaying user related information - profile data, avatar, etc. - * - The main navigation section is related to the user’s current work context - * - The secondary section is mostly used to link additional information that may be of interest (legal - * information, developer communities, external help, contact information and so on). - * - * Usage: - * - * Use the available `sap.ui.webc.fiori.SideNavigationItem` and `sap.ui.webc.fiori.SideNavigationSubItem` - * components to build your menu. The items can consist of text only or an icon with text. The use or non-use - * of icons must be consistent for all items on one level. You must not combine entries with and without - * icons on the same level. We strongly recommend that you do not use icons on the second level. - * - * Keyboard Handling: - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class SideNavigation extends WebComponent { - /** - * Constructor for a new `SideNavigation`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SideNavigationSettings - ); - /** - * Constructor for a new `SideNavigation`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SideNavigationSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.SideNavigation with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.SideNavigation. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some fixedItem to the aggregation {@link #getFixedItems fixedItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addFixedItem( - /** - * The fixedItem to add; if empty, nothing is inserted - */ - oFixedItem: ISideNavigationItem - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ISideNavigationItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.fiori.SideNavigation`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.SideNavigation` itself. - * - * Fired when the selection has changed via user interaction - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: SideNavigation$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.SideNavigation` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.fiori.SideNavigation`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.SideNavigation` itself. - * - * Fired when the selection has changed via user interaction - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: SideNavigation$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.SideNavigation` itself - */ - oListener?: object - ): this; - /** - * Destroys all the fixedItems in the aggregation {@link #getFixedItems fixedItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyFixedItems(): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.fiori.SideNavigation`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: SideNavigation$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: SideNavigation$SelectionChangeEventParameters - ): boolean; - /** - * Gets current value of property {@link #getCollapsed collapsed}. - * - * Defines whether the `sap.ui.webc.fiori.SideNavigation` is expanded or collapsed. - * - * Default value is `false`. - * - * - * @returns Value of property `collapsed` - */ - getCollapsed(): boolean; - /** - * Gets content of aggregation {@link #getFixedItems fixedItems}. - * - * Defines the fixed items at the bottom of the `sap.ui.webc.fiori.SideNavigation`. Use the `sap.ui.webc.fiori.SideNavigationItem` - * component for the fixed items, and optionally the `sap.ui.webc.fiori.SideNavigationSubItem` component - * to provide second-level items inside them. - * - * **Note:** In order to achieve the best user experience, it is recommended that you keep the fixed items - * "flat" (do not pass sub-items) - */ - getFixedItems(): ISideNavigationItem[]; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the header of the `sap.ui.webc.fiori.SideNavigation`. - * - * - * - * **Note:** The header is displayed when the component is expanded - the property `collapsed` is false; - */ - getHeader(): Control[]; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the main items of the `sap.ui.webc.fiori.SideNavigation`. Use the `sap.ui.webc.fiori.SideNavigationItem` - * component for the top-level items, and the `sap.ui.webc.fiori.SideNavigationSubItem` component for second-level - * items, nested inside the items. - */ - getItems(): ISideNavigationItem[]; - /** - * Checks for the provided `sap.ui.webc.fiori.ISideNavigationItem` in the aggregation {@link #getFixedItems fixedItems}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfFixedItem( - /** - * The fixedItem whose index is looked for - */ - oFixedItem: ISideNavigationItem - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.fiori.ISideNavigationItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ISideNavigationItem - ): int; - /** - * Inserts a fixedItem into the aggregation {@link #getFixedItems fixedItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertFixedItem( - /** - * The fixedItem to insert; if empty, nothing is inserted - */ - oFixedItem: ISideNavigationItem, - /** - * The `0`-based index the fixedItem should be inserted at; for a negative value of `iIndex`, the fixedItem - * is inserted at position 0; for a value greater than the current size of the aggregation, the fixedItem - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ISideNavigationItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getFixedItems fixedItems}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllFixedItems(): ISideNavigationItem[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ISideNavigationItem[]; - /** - * Removes a fixedItem from the aggregation {@link #getFixedItems fixedItems}. - * - * - * @returns The removed fixedItem or `null` - */ - removeFixedItem( - /** - * The fixedItem to remove or its index or id - */ - vFixedItem: int | string | ISideNavigationItem - ): ISideNavigationItem | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ISideNavigationItem - ): ISideNavigationItem | null; - /** - * Sets a new value for property {@link #getCollapsed collapsed}. - * - * Defines whether the `sap.ui.webc.fiori.SideNavigation` is expanded or collapsed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setCollapsed( - /** - * New value for property `collapsed` - */ - bCollapsed?: boolean - ): this; - } - /** - * Describes the settings that can be provided to the SideNavigation constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SideNavigationSettings extends $WebComponentSettings { - /** - * Defines whether the `sap.ui.webc.fiori.SideNavigation` is expanded or collapsed. - */ - collapsed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the fixed items at the bottom of the `sap.ui.webc.fiori.SideNavigation`. Use the `sap.ui.webc.fiori.SideNavigationItem` - * component for the fixed items, and optionally the `sap.ui.webc.fiori.SideNavigationSubItem` component - * to provide second-level items inside them. - * - * **Note:** In order to achieve the best user experience, it is recommended that you keep the fixed items - * "flat" (do not pass sub-items) - */ - fixedItems?: - | ISideNavigationItem[] - | ISideNavigationItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Defines the header of the `sap.ui.webc.fiori.SideNavigation`. - * - * - * - * **Note:** The header is displayed when the component is expanded - the property `collapsed` is false; - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the main items of the `sap.ui.webc.fiori.SideNavigation`. Use the `sap.ui.webc.fiori.SideNavigationItem` - * component for the top-level items, and the `sap.ui.webc.fiori.SideNavigationSubItem` component for second-level - * items, nested inside the items. - */ - items?: - | ISideNavigationItem[] - | ISideNavigationItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the selection has changed via user interaction - */ - selectionChange?: (oEvent: SideNavigation$SelectionChangeEvent) => void; - } - - /** - * Parameters of the SideNavigation#selectionChange event. - */ - export interface SideNavigation$SelectionChangeEventParameters { - /** - * the clicked item. - */ - item?: ISideNavigationItem | ISideNavigationSubItem; - } - - /** - * Event object of the SideNavigation#selectionChange event. - */ - export type SideNavigation$SelectionChangeEvent = Event< - SideNavigation$SelectionChangeEventParameters, - SideNavigation - >; -} - -declare module "sap/ui/webc/fiori/SideNavigationItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - ISideNavigationItem, - ISideNavigationSubItem, - } from "sap/ui/webc/fiori/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.SideNavigationItem` is used within `sap.ui.webc.fiori.SideNavigation` only. Via - * the `sap.ui.webc.fiori.SideNavigationItem` you control the content of the `SideNavigation`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class SideNavigationItem - extends WebComponent - implements ISideNavigationItem - { - __implements__sap_ui_webc_fiori_ISideNavigationItem: boolean; - /** - * Constructor for a new `SideNavigationItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SideNavigationItemSettings - ); - /** - * Constructor for a new `SideNavigationItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SideNavigationItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.SideNavigationItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.SideNavigationItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ISideNavigationSubItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.SideNavigationItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.SideNavigationItem` itself. - * - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.SideNavigationItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.SideNavigationItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.SideNavigationItem` itself. - * - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.SideNavigationItem` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.fiori.SideNavigationItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getExpanded expanded}. - * - * Defines if the item is expanded - * - * Default value is `false`. - * - * - * @returns Value of property `expanded` - */ - getExpanded(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon of the item. - * - * - * - * The SAP-icons font provides numerous options. - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines nested items by passing `sap.ui.webc.fiori.SideNavigationSubItem` to the default slot. - */ - getItems(): ISideNavigationSubItem[]; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines whether the subitem is selected - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWholeItemToggleable wholeItemToggleable}. - * - * Defines whether pressing the whole item or only pressing the icon will show/hide the items's sub items(if - * present). If set to true, pressing the whole item will toggle the sub items, and it won't fire the `click` - * event. By default, only pressing the arrow icon will toggle the sub items & the click event will be fired - * if the item is pressed outside of the icon. - * - * Default value is `false`. - * - * - * @returns Value of property `wholeItemToggleable` - */ - getWholeItemToggleable(): boolean; - /** - * Checks for the provided `sap.ui.webc.fiori.ISideNavigationSubItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ISideNavigationSubItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ISideNavigationSubItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ISideNavigationSubItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ISideNavigationSubItem - ): ISideNavigationSubItem | null; - /** - * Sets a new value for property {@link #getExpanded expanded}. - * - * Defines if the item is expanded - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setExpanded( - /** - * New value for property `expanded` - */ - bExpanded?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon of the item. - * - * - * - * The SAP-icons font provides numerous options. - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines whether the subitem is selected - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWholeItemToggleable wholeItemToggleable}. - * - * Defines whether pressing the whole item or only pressing the icon will show/hide the items's sub items(if - * present). If set to true, pressing the whole item will toggle the sub items, and it won't fire the `click` - * event. By default, only pressing the arrow icon will toggle the sub items & the click event will be fired - * if the item is pressed outside of the icon. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWholeItemToggleable( - /** - * New value for property `wholeItemToggleable` - */ - bWholeItemToggleable?: boolean - ): this; - } - /** - * Describes the settings that can be provided to the SideNavigationItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SideNavigationItemSettings extends $WebComponentSettings { - /** - * Defines if the item is expanded - */ - expanded?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon of the item. - * - * - * - * The SAP-icons font provides numerous options. - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the subitem is selected - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the item. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines whether pressing the whole item or only pressing the icon will show/hide the items's sub items(if - * present). If set to true, pressing the whole item will toggle the sub items, and it won't fire the `click` - * event. By default, only pressing the arrow icon will toggle the sub items & the click event will be fired - * if the item is pressed outside of the icon. - */ - wholeItemToggleable?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines nested items by passing `sap.ui.webc.fiori.SideNavigationSubItem` to the default slot. - */ - items?: - | ISideNavigationSubItem[] - | ISideNavigationSubItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the SideNavigationItem#click event. - */ - export interface SideNavigationItem$ClickEventParameters {} - - /** - * Event object of the SideNavigationItem#click event. - */ - export type SideNavigationItem$ClickEvent = Event< - SideNavigationItem$ClickEventParameters, - SideNavigationItem - >; -} - -declare module "sap/ui/webc/fiori/SideNavigationSubItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ISideNavigationSubItem } from "sap/ui/webc/fiori/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.SideNavigationSubItem` is intended to be used inside a `sap.ui.webc.fiori.SideNavigationItem` - * only. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class SideNavigationSubItem - extends WebComponent - implements ISideNavigationSubItem - { - __implements__sap_ui_webc_fiori_ISideNavigationSubItem: boolean; - /** - * Constructor for a new `SideNavigationSubItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SideNavigationSubItemSettings - ); - /** - * Constructor for a new `SideNavigationSubItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SideNavigationSubItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.SideNavigationSubItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.SideNavigationSubItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.SideNavigationSubItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.SideNavigationSubItem` itself. - * - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.SideNavigationSubItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.fiori.SideNavigationSubItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.SideNavigationSubItem` itself. - * - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.SideNavigationSubItem` - * itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.fiori.SideNavigationSubItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon of the item. - * - * - * - * The SAP-icons font provides numerous options. - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines whether the subitem is selected. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon of the item. - * - * - * - * The SAP-icons font provides numerous options. - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines whether the subitem is selected. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the SideNavigationSubItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SideNavigationSubItemSettings - extends $WebComponentSettings { - /** - * Defines the icon of the item. - * - * - * - * The SAP-icons font provides numerous options. - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the subitem is selected. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the item. - */ - text?: string | PropertyBindingInfo; - - /** - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the SideNavigationSubItem#click event. - */ - export interface SideNavigationSubItem$ClickEventParameters {} - - /** - * Event object of the SideNavigationSubItem#click event. - */ - export type SideNavigationSubItem$ClickEvent = Event< - SideNavigationSubItem$ClickEventParameters, - SideNavigationSubItem - >; -} - -declare module "sap/ui/webc/fiori/SortItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ISortItem } from "sap/ui/webc/fiori/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * Usage: - * - * @since 1.97.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export default class SortItem extends WebComponent implements ISortItem { - __implements__sap_ui_webc_fiori_ISortItem: boolean; - /** - * Constructor for a new `SortItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SortItemSettings - ); - /** - * Constructor for a new `SortItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SortItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.SortItem with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.SortItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines if the component is selected. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines if the component is selected. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the SortItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export interface $SortItemSettings extends $WebComponentSettings { - /** - * Defines if the component is selected. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/fiori/Timeline" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITimelineItem, TimelineLayout } from "sap/ui/webc/fiori/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.Timeline` component shows entries (such as objects, events, or posts) in chronological - * order. A common use case is to provide information about changes to an object, or events related to an - * object. These entries can be generated by the system (for example, value XY changed from A to B), or - * added manually. There are two distinct variants of the timeline: basic and social. The basic timeline - * is read-only, while the social timeline offers a high level of interaction and collaboration, and is - * integrated within SAP Jam. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Timeline extends WebComponent { - /** - * Constructor for a new `Timeline`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TimelineSettings - ); - /** - * Constructor for a new `Timeline`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TimelineSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.Timeline with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.Timeline. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ITimelineItem - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Determines the content of the `sap.ui.webc.fiori.Timeline`. - */ - getItems(): ITimelineItem[]; - /** - * Gets current value of property {@link #getLayout layout}. - * - * Defines the items orientation. - * - * - * - * **Note:** Available options are: - * - `Vertical` - * - `Horizontal` - * - * Default value is `Vertical`. - * - * - * @returns Value of property `layout` - */ - getLayout(): TimelineLayout; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.fiori.ITimelineItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ITimelineItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ITimelineItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ITimelineItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ITimelineItem - ): ITimelineItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getLayout layout}. - * - * Defines the items orientation. - * - * - * - * **Note:** Available options are: - * - `Vertical` - * - `Horizontal` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Vertical`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLayout( - /** - * New value for property `layout` - */ - sLayout?: TimelineLayout | keyof typeof TimelineLayout - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Timeline constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TimelineSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the items orientation. - * - * - * - * **Note:** Available options are: - * - `Vertical` - * - `Horizontal` - */ - layout?: - | (TimelineLayout | keyof typeof TimelineLayout) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the content of the `sap.ui.webc.fiori.Timeline`. - */ - items?: - | ITimelineItem[] - | ITimelineItem - | AggregationBindingInfo - | `{${string}}`; - } -} - -declare module "sap/ui/webc/fiori/TimelineItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITimelineItem } from "sap/ui/webc/fiori/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * An entry posted on the timeline. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TimelineItem - extends WebComponent - implements ITimelineItem - { - __implements__sap_ui_webc_fiori_ITimelineItem: boolean; - /** - * Constructor for a new `TimelineItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TimelineItemSettings - ); - /** - * Constructor for a new `TimelineItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TimelineItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.TimelineItem with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.TimelineItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:nameClick nameClick} event of this `sap.ui.webc.fiori.TimelineItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.TimelineItem` itself. - * - * Fired when the item name is pressed either with a click/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `name-clickable` attribute is not set. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachNameClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.TimelineItem` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:nameClick nameClick} event of this `sap.ui.webc.fiori.TimelineItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.TimelineItem` itself. - * - * Fired when the item name is pressed either with a click/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `name-clickable` attribute is not set. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachNameClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.TimelineItem` itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:nameClick nameClick} event of this `sap.ui.webc.fiori.TimelineItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachNameClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:nameClick nameClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireNameClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Determines the description of the `sap.ui.webc.fiori.TimelineItem`. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon to be displayed as graphical element within the `sap.ui.webc.fiori.TimelineItem`. SAP-icons - * font provides numerous options. - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getName name}. - * - * Defines the name of the item, displayed before the `title-text`. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getNameClickable nameClickable}. - * - * Defines if the `name` is clickable. - * - * Default value is `false`. - * - * - * @returns Value of property `nameClickable` - */ - getNameClickable(): boolean; - /** - * Gets current value of property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `subtitleText` - */ - getSubtitleText(): string; - /** - * Gets current value of property {@link #getTitleText titleText}. - * - * Defines the title text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `titleText` - */ - getTitleText(): string; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon to be displayed as graphical element within the `sap.ui.webc.fiori.TimelineItem`. SAP-icons - * font provides numerous options. - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Defines the name of the item, displayed before the `title-text`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getNameClickable nameClickable}. - * - * Defines if the `name` is clickable. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNameClickable( - /** - * New value for property `nameClickable` - */ - bNameClickable?: boolean - ): this; - /** - * Sets a new value for property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSubtitleText( - /** - * New value for property `subtitleText` - */ - sSubtitleText?: string - ): this; - /** - * Sets a new value for property {@link #getTitleText titleText}. - * - * Defines the title text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitleText( - /** - * New value for property `titleText` - */ - sTitleText?: string - ): this; - } - /** - * Describes the settings that can be provided to the TimelineItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TimelineItemSettings extends $WebComponentSettings { - /** - * Defines the icon to be displayed as graphical element within the `sap.ui.webc.fiori.TimelineItem`. SAP-icons - * font provides numerous options. - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the name of the item, displayed before the `title-text`. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines if the `name` is clickable. - */ - nameClickable?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the subtitle text of the component. - */ - subtitleText?: string | PropertyBindingInfo; - - /** - * Defines the title text of the component. - */ - titleText?: string | PropertyBindingInfo; - - /** - * Determines the description of the `sap.ui.webc.fiori.TimelineItem`. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the item name is pressed either with a click/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `name-clickable` attribute is not set. - */ - nameClick?: (oEvent: Event) => void; - } - - /** - * Parameters of the TimelineItem#nameClick event. - */ - export interface TimelineItem$NameClickEventParameters {} - - /** - * Event object of the TimelineItem#nameClick event. - */ - export type TimelineItem$NameClickEvent = Event< - TimelineItem$NameClickEventParameters, - TimelineItem - >; -} - -declare module "sap/ui/webc/fiori/UploadCollection" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Control from "sap/ui/core/Control"; - - import { IUploadCollectionItem } from "sap/ui/webc/fiori/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { ListMode } from "sap/ui/webc/main/library"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: This component allows you to represent files before uploading them to a server, with the help - * of `sap.ui.webc.fiori.UploadCollectionItem`. It also allows you to show already uploaded files. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class UploadCollection extends WebComponent { - /** - * Constructor for a new `UploadCollection`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $UploadCollectionSettings - ); - /** - * Constructor for a new `UploadCollection`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $UploadCollectionSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.UploadCollection with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.UploadCollection. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IUploadCollectionItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:drop drop} event of this `sap.ui.webc.fiori.UploadCollection`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollection` itself. - * - * Fired when an element is dropped inside the drag and drop overlay. - * - * **Note:** The `drop` event is fired only when elements are dropped within the drag and drop overlay - * and ignored for the other parts of the `sap.ui.webc.fiori.UploadCollection`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDrop( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: UploadCollection$DropEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollection` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:drop drop} event of this `sap.ui.webc.fiori.UploadCollection`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollection` itself. - * - * Fired when an element is dropped inside the drag and drop overlay. - * - * **Note:** The `drop` event is fired only when elements are dropped within the drag and drop overlay - * and ignored for the other parts of the `sap.ui.webc.fiori.UploadCollection`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDrop( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: UploadCollection$DropEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollection` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.fiori.UploadCollection`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollection` itself. - * - * Fired when the delete button of any item is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemDelete( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: UploadCollection$ItemDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollection` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.fiori.UploadCollection`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollection` itself. - * - * Fired when the delete button of any item is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemDelete( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: UploadCollection$ItemDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollection` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.fiori.UploadCollection`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollection` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: UploadCollection$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollection` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.fiori.UploadCollection`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollection` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: UploadCollection$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollection` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:drop drop} event of this `sap.ui.webc.fiori.UploadCollection`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachDrop( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: UploadCollection$DropEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.fiori.UploadCollection`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemDelete( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: UploadCollection$ItemDeleteEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.fiori.UploadCollection`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: UploadCollection$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:drop drop} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireDrop( - /** - * Parameters to pass along with the event - */ - mParameters?: UploadCollection$DropEventParameters - ): this; - /** - * Fires event {@link #event:itemDelete itemDelete} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemDelete( - /** - * Parameters to pass along with the event - */ - mParameters?: UploadCollection$ItemDeleteEventParameters - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: UploadCollection$SelectionChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the `sap.ui.webc.fiori.UploadCollection` header. - * - * **Note:** If `header` slot is provided, the labelling of the `UploadCollection` is a responsibility - * of the application developer. `accessibleName` should be used. - */ - getHeader(): Control[]; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getHideDragOverlay hideDragOverlay}. - * - * By default there will be drag and drop overlay shown over the `sap.ui.webc.fiori.UploadCollection` when - * files are dragged. If you don't intend to use drag and drop, set this property. - * - * **Note:** It is up to the application developer to add handler for `drop` event and handle it. `sap.ui.webc.fiori.UploadCollection` - * only displays an overlay. - * - * Default value is `false`. - * - * - * @returns Value of property `hideDragOverlay` - */ - getHideDragOverlay(): boolean; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the `sap.ui.webc.fiori.UploadCollection`. - * **Note:** Use `sap.ui.webc.fiori.UploadCollectionItem` for the intended design. - */ - getItems(): IUploadCollectionItem[]; - /** - * Gets current value of property {@link #getMode mode}. - * - * Defines the mode of the `sap.ui.webc.fiori.UploadCollection`. - * - * - * **Note:** Mode "Delete" has no effect. The delete button is controlled by the `hideDeleteButton` property - * of UploadCollectionItem - * - * Default value is `None`. - * - * - * @returns Value of property `mode` - */ - getMode(): ListMode; - /** - * Gets current value of property {@link #getNoDataDescription noDataDescription}. - * - * Allows you to set your own text for the 'No data' description. - * - * Default value is `empty string`. - * - * - * @returns Value of property `noDataDescription` - */ - getNoDataDescription(): string; - /** - * Gets current value of property {@link #getNoDataText noDataText}. - * - * Allows you to set your own text for the 'No data' text. - * - * Default value is `empty string`. - * - * - * @returns Value of property `noDataText` - */ - getNoDataText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.fiori.IUploadCollectionItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IUploadCollectionItem - ): int; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IUploadCollectionItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IUploadCollectionItem[]; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IUploadCollectionItem - ): IUploadCollectionItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getHideDragOverlay hideDragOverlay}. - * - * By default there will be drag and drop overlay shown over the `sap.ui.webc.fiori.UploadCollection` when - * files are dragged. If you don't intend to use drag and drop, set this property. - * - * **Note:** It is up to the application developer to add handler for `drop` event and handle it. `sap.ui.webc.fiori.UploadCollection` - * only displays an overlay. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideDragOverlay( - /** - * New value for property `hideDragOverlay` - */ - bHideDragOverlay?: boolean - ): this; - /** - * Sets a new value for property {@link #getMode mode}. - * - * Defines the mode of the `sap.ui.webc.fiori.UploadCollection`. - * - * - * **Note:** Mode "Delete" has no effect. The delete button is controlled by the `hideDeleteButton` property - * of UploadCollectionItem - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMode( - /** - * New value for property `mode` - */ - sMode?: ListMode | keyof typeof ListMode - ): this; - /** - * Sets a new value for property {@link #getNoDataDescription noDataDescription}. - * - * Allows you to set your own text for the 'No data' description. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoDataDescription( - /** - * New value for property `noDataDescription` - */ - sNoDataDescription?: string - ): this; - /** - * Sets a new value for property {@link #getNoDataText noDataText}. - * - * Allows you to set your own text for the 'No data' text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoDataText( - /** - * New value for property `noDataText` - */ - sNoDataText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the UploadCollection constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $UploadCollectionSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * By default there will be drag and drop overlay shown over the `sap.ui.webc.fiori.UploadCollection` when - * files are dragged. If you don't intend to use drag and drop, set this property. - * - * **Note:** It is up to the application developer to add handler for `drop` event and handle it. `sap.ui.webc.fiori.UploadCollection` - * only displays an overlay. - */ - hideDragOverlay?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the mode of the `sap.ui.webc.fiori.UploadCollection`. - * - * - * **Note:** Mode "Delete" has no effect. The delete button is controlled by the `hideDeleteButton` property - * of UploadCollectionItem - */ - mode?: - | (ListMode | keyof typeof ListMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Allows you to set your own text for the 'No data' description. - */ - noDataDescription?: string | PropertyBindingInfo; - - /** - * Allows you to set your own text for the 'No data' text. - */ - noDataText?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `sap.ui.webc.fiori.UploadCollection` header. - * - * **Note:** If `header` slot is provided, the labelling of the `UploadCollection` is a responsibility - * of the application developer. `accessibleName` should be used. - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the items of the `sap.ui.webc.fiori.UploadCollection`. - * **Note:** Use `sap.ui.webc.fiori.UploadCollectionItem` for the intended design. - */ - items?: - | IUploadCollectionItem[] - | IUploadCollectionItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when an element is dropped inside the drag and drop overlay. - * - * **Note:** The `drop` event is fired only when elements are dropped within the drag and drop overlay - * and ignored for the other parts of the `sap.ui.webc.fiori.UploadCollection`. - */ - drop?: (oEvent: UploadCollection$DropEvent) => void; - - /** - * Fired when the delete button of any item is pressed. - */ - itemDelete?: (oEvent: UploadCollection$ItemDeleteEvent) => void; - - /** - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - */ - selectionChange?: (oEvent: UploadCollection$SelectionChangeEvent) => void; - } - - /** - * Parameters of the UploadCollection#drop event. - */ - export interface UploadCollection$DropEventParameters { - /** - * The `drop` event operation data. - */ - dataTransfer?: DataTransfer; - } - - /** - * Event object of the UploadCollection#drop event. - */ - export type UploadCollection$DropEvent = Event< - UploadCollection$DropEventParameters, - UploadCollection - >; - - /** - * Parameters of the UploadCollection#itemDelete event. - */ - export interface UploadCollection$ItemDeleteEventParameters { - /** - * The `sap.ui.webc.fiori.UploadCollectionItem` which was deleted. - */ - item?: HTMLElement; - } - - /** - * Event object of the UploadCollection#itemDelete event. - */ - export type UploadCollection$ItemDeleteEvent = Event< - UploadCollection$ItemDeleteEventParameters, - UploadCollection - >; - - /** - * Parameters of the UploadCollection#selectionChange event. - */ - export interface UploadCollection$SelectionChangeEventParameters { - /** - * An array of the selected items. - */ - selectedItems?: any[]; - } - - /** - * Event object of the UploadCollection#selectionChange event. - */ - export type UploadCollection$SelectionChangeEvent = Event< - UploadCollection$SelectionChangeEventParameters, - UploadCollection - >; -} - -declare module "sap/ui/webc/fiori/UploadCollectionItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - IUploadCollectionItem, - UploadState, - } from "sap/ui/webc/fiori/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { IButton, ListItemType } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: A component to be used within the `sap.ui.webc.fiori.UploadCollection`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class UploadCollectionItem - extends WebComponent - implements IUploadCollectionItem - { - __implements__sap_ui_webc_fiori_IUploadCollectionItem: boolean; - /** - * Constructor for a new `UploadCollectionItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $UploadCollectionItemSettings - ); - /** - * Constructor for a new `UploadCollectionItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $UploadCollectionItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.UploadCollectionItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.UploadCollectionItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:fileNameClick fileNameClick} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the file name is clicked. - * - * **Note:** This event is only available when `fileNameClickable` property is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachFileNameClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:fileNameClick fileNameClick} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the file name is clicked. - * - * **Note:** This event is only available when `fileNameClickable` property is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachFileNameClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:rename rename} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the `fileName` property gets changed. - * - * **Note:** An edit button is displayed on each item, when the `sap.ui.webc.fiori.UploadCollectionItem` - * `type` property is set to `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachRename( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:rename rename} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the `fileName` property gets changed. - * - * **Note:** An edit button is displayed on each item, when the `sap.ui.webc.fiori.UploadCollectionItem` - * `type` property is set to `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachRename( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:retry retry} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the retry button is pressed. - * - * **Note:** Retry button is displayed when `uploadState` property is set to `Error`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachRetry( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:retry retry} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the retry button is pressed. - * - * **Note:** Retry button is displayed when `uploadState` property is set to `Error`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachRetry( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:terminate terminate} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the terminate button is pressed. - * - * **Note:** Terminate button is displayed when `uploadState` property is set to `Uploading`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachTerminate( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:terminate terminate} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.UploadCollectionItem` itself. - * - * Fired when the terminate button is pressed. - * - * **Note:** Terminate button is displayed when `uploadState` property is set to `Uploading`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachTerminate( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.UploadCollectionItem` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys the deleteButton in the aggregation {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyDeleteButton(): this; - /** - * Destroys the thumbnail in the aggregation {@link #getThumbnail thumbnail}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyThumbnail(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:detailClick detailClick} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachDetailClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:fileNameClick fileNameClick} event of this - * `sap.ui.webc.fiori.UploadCollectionItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachFileNameClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:rename rename} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachRename( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:retry retry} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachRetry( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:terminate terminate} event of this `sap.ui.webc.fiori.UploadCollectionItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachTerminate( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:detailClick detailClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireDetailClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:fileNameClick fileNameClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireFileNameClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:rename rename} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireRename( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:retry retry} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireRetry( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:terminate terminate} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireTerminate( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Hold the description of the `sap.ui.webc.fiori.UploadCollectionItem`. Will be shown below the file name. - */ - getContent(): Control[]; - /** - * Gets content of aggregation {@link #getDeleteButton deleteButton}. - * - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - getDeleteButton(): IButton; - /** - * Gets current value of property {@link #getDisableDeleteButton disableDeleteButton}. - * - * Disables the delete button. - * - * Default value is `false`. - * - * - * @returns Value of property `disableDeleteButton` - */ - getDisableDeleteButton(): boolean; - /** - * Gets current value of property {@link #getFile file}. - * - * Holds an instance of File associated with this item. - * - * - * @returns Value of property `file` - */ - getFile(): File; - /** - * Gets current value of property {@link #getFileName fileName}. - * - * The name of the file. - * - * Default value is `empty string`. - * - * - * @returns Value of property `fileName` - */ - getFileName(): string; - /** - * Gets current value of property {@link #getFileNameClickable fileNameClickable}. - * - * If set to `true` the file name will be clickable and it will fire `file-name-click` event upon click. - * - * Default value is `false`. - * - * - * @returns Value of property `fileNameClickable` - */ - getFileNameClickable(): boolean; - /** - * Gets current value of property {@link #getHideDeleteButton hideDeleteButton}. - * - * By default, the delete button will always be shown, regardless of the `sap.ui.webc.fiori.UploadCollection`'s - * property `mode`. Setting this property to `true` will hide the delete button. - * - * Default value is `false`. - * - * - * @returns Value of property `hideDeleteButton` - */ - getHideDeleteButton(): boolean; - /** - * Gets current value of property {@link #getHideRetryButton hideRetryButton}. - * - * Hides the retry button when `uploadState` property is `Error`. - * - * Default value is `false`. - * - * - * @returns Value of property `hideRetryButton` - */ - getHideRetryButton(): boolean; - /** - * Gets current value of property {@link #getHideTerminateButton hideTerminateButton}. - * - * Hides the terminate button when `uploadState` property is `Uploading`. - * - * Default value is `false`. - * - * - * @returns Value of property `hideTerminateButton` - */ - getHideTerminateButton(): boolean; - /** - * Gets current value of property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * - * @returns Value of property `navigated` - */ - getNavigated(): boolean; - /** - * Gets current value of property {@link #getProgress progress}. - * - * The upload progress in percentage. - * - * **Note:** Expected values are in the interval [0, 100]. - * - * Default value is `0`. - * - * - * @returns Value of property `progress` - */ - getProgress(): int; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets content of aggregation {@link #getThumbnail thumbnail}. - * - * A thumbnail, which will be shown in the beginning of the `sap.ui.webc.fiori.UploadCollectionItem`. - * - * **Note:** Use `sap.ui.webc.main.Icon` or `img` for the intended design. - */ - getThumbnail(): Control; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * Default value is `Active`. - * - * - * @returns Value of property `type` - */ - getType(): ListItemType; - /** - * Gets current value of property {@link #getUploadState uploadState}. - * - * If set to `Uploading` or `Error`, a progress indicator showing the `progress` is displayed. Also if set - * to `Error`, a refresh button is shown. When this icon is pressed `retry` event is fired. If set to `Uploading`, - * a terminate button is shown. When this icon is pressed `terminate` event is fired. - * - * Default value is `Ready`. - * - * - * @returns Value of property `uploadState` - */ - getUploadState(): UploadState; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets the aggregated {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDeleteButton( - /** - * The deleteButton to set - */ - oDeleteButton: IButton - ): this; - /** - * Sets a new value for property {@link #getDisableDeleteButton disableDeleteButton}. - * - * Disables the delete button. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDisableDeleteButton( - /** - * New value for property `disableDeleteButton` - */ - bDisableDeleteButton?: boolean - ): this; - /** - * Sets a new value for property {@link #setFile file}. - * - * Holds an instance of File associated with this item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFile( - /** - * New value for property `file` - */ - oFile?: File - ): this; - /** - * Sets a new value for property {@link #getFileName fileName}. - * - * The name of the file. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFileName( - /** - * New value for property `fileName` - */ - sFileName?: string - ): this; - /** - * Sets a new value for property {@link #getFileNameClickable fileNameClickable}. - * - * If set to `true` the file name will be clickable and it will fire `file-name-click` event upon click. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFileNameClickable( - /** - * New value for property `fileNameClickable` - */ - bFileNameClickable?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideDeleteButton hideDeleteButton}. - * - * By default, the delete button will always be shown, regardless of the `sap.ui.webc.fiori.UploadCollection`'s - * property `mode`. Setting this property to `true` will hide the delete button. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideDeleteButton( - /** - * New value for property `hideDeleteButton` - */ - bHideDeleteButton?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideRetryButton hideRetryButton}. - * - * Hides the retry button when `uploadState` property is `Error`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideRetryButton( - /** - * New value for property `hideRetryButton` - */ - bHideRetryButton?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideTerminateButton hideTerminateButton}. - * - * Hides the terminate button when `uploadState` property is `Uploading`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideTerminateButton( - /** - * New value for property `hideTerminateButton` - */ - bHideTerminateButton?: boolean - ): this; - /** - * Sets a new value for property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNavigated( - /** - * New value for property `navigated` - */ - bNavigated: boolean - ): this; - /** - * Sets a new value for property {@link #getProgress progress}. - * - * The upload progress in percentage. - * - * **Note:** Expected values are in the interval [0, 100]. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setProgress( - /** - * New value for property `progress` - */ - iProgress?: int - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets the aggregated {@link #getThumbnail thumbnail}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setThumbnail( - /** - * The thumbnail to set - */ - oThumbnail: Control - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Active`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ListItemType | keyof typeof ListItemType - ): this; - /** - * Sets a new value for property {@link #getUploadState uploadState}. - * - * If set to `Uploading` or `Error`, a progress indicator showing the `progress` is displayed. Also if set - * to `Error`, a refresh button is shown. When this icon is pressed `retry` event is fired. If set to `Uploading`, - * a terminate button is shown. When this icon is pressed `terminate` event is fired. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Ready`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setUploadState( - /** - * New value for property `uploadState` - */ - sUploadState?: UploadState | keyof typeof UploadState - ): this; - } - /** - * Describes the settings that can be provided to the UploadCollectionItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $UploadCollectionItemSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Disables the delete button. - */ - disableDeleteButton?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Holds an instance of `File` associated with this item. - */ - file?: object | PropertyBindingInfo | `{${string}}`; - - /** - * The name of the file. - */ - fileName?: string | PropertyBindingInfo; - - /** - * If set to `true` the file name will be clickable and it will fire `file-name-click` event upon click. - */ - fileNameClickable?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * By default, the delete button will always be shown, regardless of the `sap.ui.webc.fiori.UploadCollection`'s - * property `mode`. Setting this property to `true` will hide the delete button. - */ - hideDeleteButton?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Hides the retry button when `uploadState` property is `Error`. - */ - hideRetryButton?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Hides the terminate button when `uploadState` property is `Uploading`. - */ - hideTerminateButton?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - */ - navigated?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * The upload progress in percentage. - * - * **Note:** Expected values are in the interval [0, 100]. - */ - progress?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - */ - type?: - | (ListItemType | keyof typeof ListItemType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * If set to `Uploading` or `Error`, a progress indicator showing the `progress` is displayed. Also if set - * to `Error`, a refresh button is shown. When this icon is pressed `retry` event is fired. If set to `Uploading`, - * a terminate button is shown. When this icon is pressed `terminate` event is fired. - */ - uploadState?: - | (UploadState | keyof typeof UploadState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Hold the description of the `sap.ui.webc.fiori.UploadCollectionItem`. Will be shown below the file name. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - deleteButton?: IButton; - - /** - * A thumbnail, which will be shown in the beginning of the `sap.ui.webc.fiori.UploadCollectionItem`. - * - * **Note:** Use `sap.ui.webc.main.Icon` or `img` for the intended design. - */ - thumbnail?: Control; - - /** - * Fired when the user clicks on the detail button when type is `Detail`. - */ - detailClick?: (oEvent: Event) => void; - - /** - * Fired when the file name is clicked. - * - * **Note:** This event is only available when `fileNameClickable` property is `true`. - */ - fileNameClick?: (oEvent: Event) => void; - - /** - * Fired when the `fileName` property gets changed. - * - * **Note:** An edit button is displayed on each item, when the `sap.ui.webc.fiori.UploadCollectionItem` - * `type` property is set to `Detail`. - */ - rename?: (oEvent: Event) => void; - - /** - * Fired when the retry button is pressed. - * - * **Note:** Retry button is displayed when `uploadState` property is set to `Error`. - */ - retry?: (oEvent: Event) => void; - - /** - * Fired when the terminate button is pressed. - * - * **Note:** Terminate button is displayed when `uploadState` property is set to `Uploading`. - */ - terminate?: (oEvent: Event) => void; - } - - /** - * Parameters of the UploadCollectionItem#detailClick event. - */ - export interface UploadCollectionItem$DetailClickEventParameters {} - - /** - * Event object of the UploadCollectionItem#detailClick event. - */ - export type UploadCollectionItem$DetailClickEvent = Event< - UploadCollectionItem$DetailClickEventParameters, - UploadCollectionItem - >; - - /** - * Parameters of the UploadCollectionItem#fileNameClick event. - */ - export interface UploadCollectionItem$FileNameClickEventParameters {} - - /** - * Event object of the UploadCollectionItem#fileNameClick event. - */ - export type UploadCollectionItem$FileNameClickEvent = Event< - UploadCollectionItem$FileNameClickEventParameters, - UploadCollectionItem - >; - - /** - * Parameters of the UploadCollectionItem#rename event. - */ - export interface UploadCollectionItem$RenameEventParameters {} - - /** - * Event object of the UploadCollectionItem#rename event. - */ - export type UploadCollectionItem$RenameEvent = Event< - UploadCollectionItem$RenameEventParameters, - UploadCollectionItem - >; - - /** - * Parameters of the UploadCollectionItem#retry event. - */ - export interface UploadCollectionItem$RetryEventParameters {} - - /** - * Event object of the UploadCollectionItem#retry event. - */ - export type UploadCollectionItem$RetryEvent = Event< - UploadCollectionItem$RetryEventParameters, - UploadCollectionItem - >; - - /** - * Parameters of the UploadCollectionItem#terminate event. - */ - export interface UploadCollectionItem$TerminateEventParameters {} - - /** - * Event object of the UploadCollectionItem#terminate event. - */ - export type UploadCollectionItem$TerminateEvent = Event< - UploadCollectionItem$TerminateEventParameters, - UploadCollectionItem - >; -} - -declare module "sap/ui/webc/fiori/ViewSettingsDialog" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFilterItem, ISortItem } from "sap/ui/webc/fiori/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.fiori.ViewSettingsDialog` component helps the user to sort data within a list - * or a table. It consists of several lists like `Sort order` which is built-in and `Sort By` and `Filter - * By` lists, for which you must be provide items(`sap.ui.webc.fiori.SortItem` & `sap.ui.webc.fiori.FilterItem` - * respectively) These options can be used to create sorters for a table. - * - * The `sap.ui.webc.fiori.ViewSettingsDialog` interrupts the current application processing as it is the - * only focused UI element and the main screen is dimmed/blocked. The `sap.ui.webc.fiori.ViewSettingsDialog` - * is modal, which means that user action is required before returning to the parent window is possible. - * - * Structure: A `sap.ui.webc.fiori.ViewSettingsDialog` consists of a header, content, and a footer for action - * buttons. The `sap.ui.webc.fiori.ViewSettingsDialog` is usually displayed at the center of the screen. - * - * Responsive Behavior: `sap.ui.webc.fiori.ViewSettingsDialog` stretches on full screen on phones. - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class ViewSettingsDialog extends WebComponent { - /** - * Constructor for a new `ViewSettingsDialog`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ViewSettingsDialogSettings - ); - /** - * Constructor for a new `ViewSettingsDialog`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ViewSettingsDialogSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.ViewSettingsDialog with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.ViewSettingsDialog. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some filterItem to the aggregation {@link #getFilterItems filterItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addFilterItem( - /** - * The filterItem to add; if empty, nothing is inserted - */ - oFilterItem: IFilterItem - ): this; - /** - * Adds some sortItem to the aggregation {@link #getSortItems sortItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addSortItem( - /** - * The sortItem to add; if empty, nothing is inserted - */ - oSortItem: ISortItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ViewSettingsDialog` itself. - * - * Fired before the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ViewSettingsDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ViewSettingsDialog` itself. - * - * Fired before the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ViewSettingsDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:cancel cancel} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ViewSettingsDialog` itself. - * - * Fired when cancel button is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachCancel( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ViewSettingsDialog$CancelEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ViewSettingsDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:cancel cancel} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ViewSettingsDialog` itself. - * - * Fired when cancel button is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachCancel( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ViewSettingsDialog$CancelEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ViewSettingsDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:confirm confirm} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ViewSettingsDialog` itself. - * - * Fired when confirmation button is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachConfirm( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ViewSettingsDialog$ConfirmEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ViewSettingsDialog` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:confirm confirm} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.ViewSettingsDialog` itself. - * - * Fired when confirmation button is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachConfirm( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ViewSettingsDialog$ConfirmEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.ViewSettingsDialog` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the filterItems in the aggregation {@link #getFilterItems filterItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyFilterItems(): this; - /** - * Destroys all the sortItems in the aggregation {@link #getSortItems sortItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySortItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:cancel cancel} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachCancel( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ViewSettingsDialog$CancelEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:confirm confirm} event of this `sap.ui.webc.fiori.ViewSettingsDialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachConfirm( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ViewSettingsDialog$ConfirmEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:beforeOpen beforeOpen} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireBeforeOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:cancel cancel} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireCancel( - /** - * Parameters to pass along with the event - */ - mParameters?: ViewSettingsDialog$CancelEventParameters - ): this; - /** - * Fires event {@link #event:confirm confirm} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireConfirm( - /** - * Parameters to pass along with the event - */ - mParameters?: ViewSettingsDialog$ConfirmEventParameters - ): this; - /** - * Gets content of aggregation {@link #getFilterItems filterItems}. - */ - getFilterItems(): IFilterItem[]; - /** - * Gets current value of property {@link #getSortDescending sortDescending}. - * - * Defines the initial sort order. - * - * Default value is `false`. - * - * - * @returns Value of property `sortDescending` - */ - getSortDescending(): boolean; - /** - * Gets content of aggregation {@link #getSortItems sortItems}. - */ - getSortItems(): ISortItem[]; - /** - * Checks for the provided `sap.ui.webc.fiori.IFilterItem` in the aggregation {@link #getFilterItems filterItems}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfFilterItem( - /** - * The filterItem whose index is looked for - */ - oFilterItem: IFilterItem - ): int; - /** - * Checks for the provided `sap.ui.webc.fiori.ISortItem` in the aggregation {@link #getSortItems sortItems}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfSortItem( - /** - * The sortItem whose index is looked for - */ - oSortItem: ISortItem - ): int; - /** - * Inserts a filterItem into the aggregation {@link #getFilterItems filterItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertFilterItem( - /** - * The filterItem to insert; if empty, nothing is inserted - */ - oFilterItem: IFilterItem, - /** - * The `0`-based index the filterItem should be inserted at; for a negative value of `iIndex`, the filterItem - * is inserted at position 0; for a value greater than the current size of the aggregation, the filterItem - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a sortItem into the aggregation {@link #getSortItems sortItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertSortItem( - /** - * The sortItem to insert; if empty, nothing is inserted - */ - oSortItem: ISortItem, - /** - * The `0`-based index the sortItem should be inserted at; for a negative value of `iIndex`, the sortItem - * is inserted at position 0; for a value greater than the current size of the aggregation, the sortItem - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getFilterItems filterItems}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllFilterItems(): IFilterItem[]; - /** - * Removes all the controls from the aggregation {@link #getSortItems sortItems}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllSortItems(): ISortItem[]; - /** - * Removes a filterItem from the aggregation {@link #getFilterItems filterItems}. - * - * - * @returns The removed filterItem or `null` - */ - removeFilterItem( - /** - * The filterItem to remove or its index or id - */ - vFilterItem: int | string | IFilterItem - ): IFilterItem | null; - /** - * Removes a sortItem from the aggregation {@link #getSortItems sortItems}. - * - * - * @returns The removed sortItem or `null` - */ - removeSortItem( - /** - * The sortItem to remove or its index or id - */ - vSortItem: int | string | ISortItem - ): ISortItem | null; - /** - * Sets a JavaScript object, as settings to the `sap.ui.webc.fiori.ViewSettingsDialog`. This method can - * be used after the dialog is initially open, as the dialog needs to set its initial settings. - * The `sap.ui.webc.fiori.ViewSettingsDialog` throws an event called "before-open", which can be used as - * a trigger point. - * The object should have the following format: - * - * ```javascript - * - * { - * sortOrder: "Ascending", - * sortBy: "Name", - * filters: [ - * {"Filter 1": ["Some filter 1", "Some filter 2"]}, - * {"Filter 2": ["Some filter 4"]}, - * ] - * } - * ``` - */ - setConfirmedSettings( - /** - * predefined settings. - */ - settings: object - ): void; - /** - * Sets a new value for property {@link #getSortDescending sortDescending}. - * - * Defines the initial sort order. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSortDescending( - /** - * New value for property `sortDescending` - */ - bSortDescending?: boolean - ): this; - /** - * Shows the dialog. - */ - show(): void; - } - /** - * Describes the settings that can be provided to the ViewSettingsDialog constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $ViewSettingsDialogSettings extends $WebComponentSettings { - /** - * Defines the initial sort order. - */ - sortDescending?: boolean | PropertyBindingInfo | `{${string}}`; - - filterItems?: - | IFilterItem[] - | IFilterItem - | AggregationBindingInfo - | `{${string}}`; - - sortItems?: - | ISortItem[] - | ISortItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired before the component is opened. **This event does not bubble.** - */ - beforeOpen?: (oEvent: Event) => void; - - /** - * Fired when cancel button is activated. - */ - cancel?: (oEvent: ViewSettingsDialog$CancelEvent) => void; - - /** - * Fired when confirmation button is activated. - */ - confirm?: (oEvent: ViewSettingsDialog$ConfirmEvent) => void; - } - - /** - * Parameters of the ViewSettingsDialog#beforeOpen event. - */ - export interface ViewSettingsDialog$BeforeOpenEventParameters {} - - /** - * Event object of the ViewSettingsDialog#beforeOpen event. - */ - export type ViewSettingsDialog$BeforeOpenEvent = Event< - ViewSettingsDialog$BeforeOpenEventParameters, - ViewSettingsDialog - >; - - /** - * Parameters of the ViewSettingsDialog#cancel event. - */ - export interface ViewSettingsDialog$CancelEventParameters { - /** - * The current sort order selected. - */ - sortOrder?: string; - - /** - * The currently selected `sap.ui.webc.fiori.SortItem` text attribute. - */ - sortBy?: string; - - /** - * The currently selected `sap.ui.webc.fiori.SortItem`. - */ - sortByItem?: HTMLElement; - - /** - * The selected sort order (true = descending, false = ascending). - */ - sortDescending?: boolean; - - /** - * The selected filters items. - */ - filters?: any[]; - } - - /** - * Event object of the ViewSettingsDialog#cancel event. - */ - export type ViewSettingsDialog$CancelEvent = Event< - ViewSettingsDialog$CancelEventParameters, - ViewSettingsDialog - >; - - /** - * Parameters of the ViewSettingsDialog#confirm event. - */ - export interface ViewSettingsDialog$ConfirmEventParameters { - /** - * The current sort order selected. - */ - sortOrder?: string; - - /** - * The currently selected `sap.ui.webc.fiori.SortItem` text attribute. - */ - sortBy?: string; - - /** - * The currently selected `sap.ui.webc.fiori.SortItem`. - */ - sortByItem?: HTMLElement; - - /** - * The selected sort order (true = descending, false = ascending). - */ - sortDescending?: boolean; - - /** - * The selected filters items. - */ - filters?: any[]; - } - - /** - * Event object of the ViewSettingsDialog#confirm event. - */ - export type ViewSettingsDialog$ConfirmEvent = Event< - ViewSettingsDialog$ConfirmEventParameters, - ViewSettingsDialog - >; -} - -declare module "sap/ui/webc/fiori/Wizard" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IWizardStep, WizardContentLayout } from "sap/ui/webc/fiori/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `sap.ui.webc.fiori.Wizard` helps users to complete a complex task by dividing it into sections and - * guiding them through it. It has two main areas - a navigation area at the top showing the step sequence - * and a content area below it. - * - * Structure: Navigation area: The top most area of the `sap.ui.webc.fiori.Wizard` is occupied by the navigation - * area. It shows the sequence of steps, where the recommended number of steps is between 3 and 8 steps. - * - * - Steps can have different visual representations - numbers or icons. - * - Steps might have labels for better readability - titleText and subTitleText. - * - Steps are defined by using the `sap.ui.webc.fiori.WizardStep` as slotted element within the `sap.ui.webc.fiori.Wizard`. - * - * - * **Note:** If no selected step is defined, the first step will be auto selected. - * **Note:** If multiple selected steps are defined, the last step will be selected. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.fiori.Wizard` exposes the following CSS Shadow Parts: - * - navigator - Used to style the progress navigator of the `sap.ui.webc.fiori.Wizard`. - * - step-content - Used to style a `sap.ui.webc.fiori.WizardStep` container. - * - * Keyboard Handling: The user can navigate using the following keyboard shortcuts: - * - * - * Wizard Progress Navigation: - * - [LEFT], [DOWN] - Focus moves backward to the WizardProgressNavAnchors. - * - [UP], [RIGHT] - Focus moves forward to the WizardProgressNavAnchor. - * - [SPACE] or [ENTER], [RETURN] - Selects an active step - * - [HOME] or [PAGE UP] - Focus goes to the first step - * - [END] or [PAGE DOWN] - Focus goes to the last step - * - * Content: The content occupies the main part of the page. It can hold any type of HTML elements. It's - * defined by using the `sap.ui.webc.fiori.WizardStep` as slotted element within the `sap.ui.webc.fiori.Wizard`. - * - * Scrolling: The component handles user scrolling by selecting the closest step, based on the current scroll - * position and scrolls to particular place, when the user clicks on the step within the navigation area. - * - * - * - * - * **Important:** In order the component's scrolling behaviour to work, it has to be limited from the outside - * parent element in terms of height. The component or its parent has to be given percentage or absolute - * height. Otherwise, the component will be scrolled out with the entire page. - * - * **For example:** - * - * ` - * ` ` - * ` `` - * - * Moving to next step: The `sap.ui.webc.fiori.WizardStep` provides the necessary API and it's up to the - * user of the component to use it to move to the next step. You have to set its `selected` property (and - * remove the `disabled` one if set) to `true`. The `sap.ui.webc.fiori.Wizard` will automatically scroll - * to the content of the newly selected step. - * - * - * - * The Fiori 3 guidelines recommends having a "nextStep" button in the content area. You can place a button, - * or any other type of element to trigger step change, inside the `sap.ui.webc.fiori.WizardStep`, and show/hide - * it when certain fields are filled or user defined criteria is met. - * - * Usage: When to use:: When the user has to accomplish a long or unfamiliar task. - * - * When not to use:: When the task has less than 3 steps. - * - * Responsive Behavior: On small widths the step's titleText, subtitleText and separators in the navigation - * area shrink and from particular point the steps are grouped together and overlap. Tapping on them will - * show a popover to select the step to navigate to. On mobile device, the grouped steps are presented within - * a dialog. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Wizard extends WebComponent { - /** - * Constructor for a new `Wizard`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $WizardSettings - ); - /** - * Constructor for a new `Wizard`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $WizardSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.Wizard with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.Wizard. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some step to the aggregation {@link #getSteps steps}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addStep( - /** - * The step to add; if empty, nothing is inserted - */ - oStep: IWizardStep - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:stepChange stepChange} event of this `sap.ui.webc.fiori.Wizard`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.Wizard` itself. - * - * Fired when the step is changed by user interaction - either with scrolling, or by clicking on the steps - * within the component header. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachStepChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Wizard$StepChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.Wizard` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:stepChange stepChange} event of this `sap.ui.webc.fiori.Wizard`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.fiori.Wizard` itself. - * - * Fired when the step is changed by user interaction - either with scrolling, or by clicking on the steps - * within the component header. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachStepChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Wizard$StepChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.fiori.Wizard` itself - */ - oListener?: object - ): this; - /** - * Destroys all the steps in the aggregation {@link #getSteps steps}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySteps(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:stepChange stepChange} event of this `sap.ui.webc.fiori.Wizard`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachStepChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Wizard$StepChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:stepChange stepChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireStepChange( - /** - * Parameters to pass along with the event - */ - mParameters?: Wizard$StepChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getContentLayout contentLayout}. - * - * Defines how the content of the `sap.ui.webc.fiori.Wizard` would be visualized. - * - * Default value is `MultipleSteps`. - * - * - * @returns Value of property `contentLayout` - */ - getContentLayout(): WizardContentLayout; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets content of aggregation {@link #getSteps steps}. - * - * Defines the steps. - * - * **Note:** Use the available `sap.ui.webc.fiori.WizardStep` component. - */ - getSteps(): IWizardStep[]; - /** - * Checks for the provided `sap.ui.webc.fiori.IWizardStep` in the aggregation {@link #getSteps steps}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfStep( - /** - * The step whose index is looked for - */ - oStep: IWizardStep - ): int; - /** - * Inserts a step into the aggregation {@link #getSteps steps}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertStep( - /** - * The step to insert; if empty, nothing is inserted - */ - oStep: IWizardStep, - /** - * The `0`-based index the step should be inserted at; for a negative value of `iIndex`, the step is inserted - * at position 0; for a value greater than the current size of the aggregation, the step is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getSteps steps}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllSteps(): IWizardStep[]; - /** - * Removes a step from the aggregation {@link #getSteps steps}. - * - * - * @returns The removed step or `null` - */ - removeStep( - /** - * The step to remove or its index or id - */ - vStep: int | string | IWizardStep - ): IWizardStep | null; - /** - * Sets a new value for property {@link #getContentLayout contentLayout}. - * - * Defines how the content of the `sap.ui.webc.fiori.Wizard` would be visualized. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `MultipleSteps`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setContentLayout( - /** - * New value for property `contentLayout` - */ - sContentLayout?: WizardContentLayout | keyof typeof WizardContentLayout - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Wizard constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $WizardSettings extends $WebComponentSettings { - /** - * Defines how the content of the `sap.ui.webc.fiori.Wizard` would be visualized. - */ - contentLayout?: - | (WizardContentLayout | keyof typeof WizardContentLayout) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the steps. - * - * **Note:** Use the available `sap.ui.webc.fiori.WizardStep` component. - */ - steps?: - | IWizardStep[] - | IWizardStep - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the step is changed by user interaction - either with scrolling, or by clicking on the steps - * within the component header. - */ - stepChange?: (oEvent: Wizard$StepChangeEvent) => void; - } - - /** - * Parameters of the Wizard#stepChange event. - */ - export interface Wizard$StepChangeEventParameters { - /** - * The new step. - */ - step?: IWizardStep; - - /** - * The previous step. - */ - previousStep?: IWizardStep; - - /** - * The step change occurs due to user's click or 'Enter'/'Space' key press on step within the navigation. - */ - changeWithClick?: boolean; - } - - /** - * Event object of the Wizard#stepChange event. - */ - export type Wizard$StepChangeEvent = Event< - Wizard$StepChangeEventParameters, - Wizard - >; -} - -declare module "sap/ui/webc/fiori/WizardStep" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IWizardStep } from "sap/ui/webc/fiori/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * A component that represents a logical step as part of the `sap.ui.webc.fiori.Wizard`. It is meant to - * aggregate arbitrary HTML elements that form the content of a single step. - * - * Structure: - * - Each wizard step has arbitrary content. - * - Each wizard step might have texts - defined by the `titleText` and `subtitleText` properties. - * - Each wizard step might have an icon - defined by the `icon` property. - * - Each wizard step might display a number in place of the `icon`, when it's missing. - * - * Usage: The `sap.ui.webc.fiori.WizardStep` component should be used only as slot of the `sap.ui.webc.fiori.Wizard` - * component and should not be used standalone. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class WizardStep extends WebComponent implements IWizardStep { - __implements__sap_ui_webc_fiori_IWizardStep: boolean; - /** - * Constructor for a new `WizardStep`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $WizardStepSettings - ); - /** - * Constructor for a new `WizardStep`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $WizardStepSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.fiori.WizardStep with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.fiori.WizardStep. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Gets current value of property {@link #getBranching branching}. - * - * When `branching` is enabled a dashed line would be displayed after the step, meant to indicate that the - * next step is not yet known and depends on user choice in the current step. - * - * - * - * **Note:** It is recommended to use `branching` on the last known step and later add new steps when it - * becomes clear how the wizard flow should continue. - * - * Default value is `false`. - * - * - * @returns Value of property `branching` - */ - getBranching(): boolean; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the step content. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the `icon` of the step. - * - * - * - * **Note:** The icon is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - * - * - * - * The SAP-icons font provides numerous options. See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the step's `selected` state - the step that is currently active. - * - * - * - * **Note:** Step can't be `selected` and `disabled` at the same time. In this case the `selected` property - * would take precedence. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getSubtitleText subtitleText}. - * - * Defines the `subtitleText` of the step. - * - * - * - * **Note:** the text is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - * - * Default value is `empty string`. - * - * - * @returns Value of property `subtitleText` - */ - getSubtitleText(): string; - /** - * Gets current value of property {@link #getTitleText titleText}. - * - * Defines the `titleText` of the step. - * - * - * - * **Note:** The text is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - * - * Default value is `empty string`. - * - * - * @returns Value of property `titleText` - */ - getTitleText(): string; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getBranching branching}. - * - * When `branching` is enabled a dashed line would be displayed after the step, meant to indicate that the - * next step is not yet known and depends on user choice in the current step. - * - * - * - * **Note:** It is recommended to use `branching` on the last known step and later add new steps when it - * becomes clear how the wizard flow should continue. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBranching( - /** - * New value for property `branching` - */ - bBranching?: boolean - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the `icon` of the step. - * - * - * - * **Note:** The icon is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - * - * - * - * The SAP-icons font provides numerous options. See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the step's `selected` state - the step that is currently active. - * - * - * - * **Note:** Step can't be `selected` and `disabled` at the same time. In this case the `selected` property - * would take precedence. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getSubtitleText subtitleText}. - * - * Defines the `subtitleText` of the step. - * - * - * - * **Note:** the text is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSubtitleText( - /** - * New value for property `subtitleText` - */ - sSubtitleText?: string - ): this; - /** - * Sets a new value for property {@link #getTitleText titleText}. - * - * Defines the `titleText` of the step. - * - * - * - * **Note:** The text is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitleText( - /** - * New value for property `titleText` - */ - sTitleText?: string - ): this; - } - /** - * Describes the settings that can be provided to the WizardStep constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $WizardStepSettings extends $WebComponentSettings { - /** - * When `branching` is enabled a dashed line would be displayed after the step, meant to indicate that the - * next step is not yet known and depends on user choice in the current step. - * - * - * - * **Note:** It is recommended to use `branching` on the last known step and later add new steps when it - * becomes clear how the wizard flow should continue. - */ - branching?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `icon` of the step. - * - * - * - * **Note:** The icon is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - * - * - * - * The SAP-icons font provides numerous options. See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the step's `selected` state - the step that is currently active. - * - * - * - * **Note:** Step can't be `selected` and `disabled` at the same time. In this case the `selected` property - * would take precedence. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `subtitleText` of the step. - * - * - * - * **Note:** the text is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - */ - subtitleText?: string | PropertyBindingInfo; - - /** - * Defines the `titleText` of the step. - * - * - * - * **Note:** The text is displayed in the `sap.ui.webc.fiori.Wizard` navigation header. - */ - titleText?: string | PropertyBindingInfo; - - /** - * Defines the step content. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - } -} - -declare namespace sap { - interface IUI5DefineDependencyNames { - "sap/ui/webc/fiori/Bar": undefined; - - "sap/ui/webc/fiori/BarcodeScannerDialog": undefined; - - "sap/ui/webc/fiori/DynamicSideContent": undefined; - - "sap/ui/webc/fiori/FilterItem": undefined; - - "sap/ui/webc/fiori/FilterItemOption": undefined; - - "sap/ui/webc/fiori/FlexibleColumnLayout": undefined; - - "sap/ui/webc/fiori/IllustratedMessage": undefined; - - "sap/ui/webc/fiori/library": undefined; - - "sap/ui/webc/fiori/MediaGallery": undefined; - - "sap/ui/webc/fiori/MediaGalleryItem": undefined; - - "sap/ui/webc/fiori/NotificationAction": undefined; - - "sap/ui/webc/fiori/NotificationListGroupItem": undefined; - - "sap/ui/webc/fiori/NotificationListItem": undefined; - - "sap/ui/webc/fiori/Page": undefined; - - "sap/ui/webc/fiori/ProductSwitch": undefined; - - "sap/ui/webc/fiori/ProductSwitchItem": undefined; - - "sap/ui/webc/fiori/ShellBar": undefined; - - "sap/ui/webc/fiori/ShellBarItem": undefined; - - "sap/ui/webc/fiori/SideNavigation": undefined; - - "sap/ui/webc/fiori/SideNavigationItem": undefined; - - "sap/ui/webc/fiori/SideNavigationSubItem": undefined; - - "sap/ui/webc/fiori/SortItem": undefined; - - "sap/ui/webc/fiori/Timeline": undefined; - - "sap/ui/webc/fiori/TimelineItem": undefined; - - "sap/ui/webc/fiori/UploadCollection": undefined; - - "sap/ui/webc/fiori/UploadCollectionItem": undefined; - - "sap/ui/webc/fiori/ViewSettingsDialog": undefined; - - "sap/ui/webc/fiori/Wizard": undefined; - - "sap/ui/webc/fiori/WizardStep": undefined; - } -} diff --git a/types/openui5/sap.ui.webc.main.d.ts b/types/openui5/sap.ui.webc.main.d.ts deleted file mode 100644 index 84d03df88e12a3..00000000000000 --- a/types/openui5/sap.ui.webc.main.d.ts +++ /dev/null @@ -1,51365 +0,0 @@ -// For Library Version: 1.146.0 - -declare module "sap/ui/webc/main/library" { - /** - * Different types of AvatarColorScheme. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'AvatarColorScheme'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum AvatarColorScheme { - Accent1 = "Accent1", - - Accent10 = "Accent10", - - Accent2 = "Accent2", - - Accent3 = "Accent3", - - Accent4 = "Accent4", - - Accent5 = "Accent5", - - Accent6 = "Accent6", - - Accent7 = "Accent7", - - Accent8 = "Accent8", - - Accent9 = "Accent9", - - Placeholder = "Placeholder", - } - /** - * Different types of AvatarGroupType. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'AvatarGroupType'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum AvatarGroupType { - /** - * The avatars are displayed as partially overlapped on top of each other and the entire group has one click - * or tap area. - */ - Group = "Group", - /** - * The avatars are displayed side-by-side and each avatar has its own click or tap area. - */ - Individual = "Individual", - } - /** - * Different types of AvatarShape. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'AvatarShape'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum AvatarShape { - /** - * Circular shape. - */ - Circle = "Circle", - /** - * Square shape. - */ - Square = "Square", - } - /** - * Different types of AvatarSize. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'AvatarSize'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum AvatarSize { - /** - * component size - 5rem font size - 2.5rem - */ - L = "L", - /** - * component size - 4rem font size - 2rem - */ - M = "M", - /** - * component size - 3rem font size - 1.5rem - */ - S = "S", - /** - * component size - 7rem font size - 3rem - */ - XL = "XL", - /** - * component size - 2rem font size - 1rem - */ - XS = "XS", - } - /** - * Defines background designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'BackgroundDesign'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum BackgroundDesign { - /** - * A solid background color dependent on the theme. - */ - Solid = "Solid", - /** - * A translucent background depending on the opacity value of the theme. - */ - Translucent = "Translucent", - /** - * Transparent background. - */ - Transparent = "Transparent", - } - /** - * Defines border designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'BorderDesign'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum BorderDesign { - /** - * Specifies no border. - */ - None = "None", - /** - * A solid border color dependent on the theme. - */ - Solid = "Solid", - } - /** - * Different Breadcrumbs designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'BreadcrumbsDesign'. - * - * @since 1.95.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.95.0. This API is experimental and might change significantly. - */ - export enum BreadcrumbsDesign { - /** - * All items are displayed as links. - */ - NoCurrentPage = "NoCurrentPage", - /** - * Shows the current page as the last item in the trail. The last item contains only plain text and is not - * a link. - */ - Standard = "Standard", - } - /** - * Different Breadcrumbs separator styles. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'BreadcrumbsSeparatorStyle'. - * - * @since 1.95.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.95.0. This API is experimental and might change significantly. - */ - export enum BreadcrumbsSeparatorStyle { - /** - * The separator appears as "\". - */ - BackSlash = "BackSlash", - /** - * The separator appears as "\\". - */ - DoubleBackSlash = "DoubleBackSlash", - /** - * The separator appears as ">>". - */ - DoubleGreaterThan = "DoubleGreaterThan", - /** - * The separator appears as "//" . - */ - DoubleSlash = "DoubleSlash", - /** - * The separator appears as ">". - */ - GreaterThan = "GreaterThan", - /** - * The separator appears as "/". - */ - Slash = "Slash", - } - /** - * Different BusyIndicator sizes. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'BusyIndicatorSize'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum BusyIndicatorSize { - /** - * large size - */ - Large = "Large", - /** - * medium size - */ - Medium = "Medium", - /** - * small size - */ - Small = "Small", - } - /** - * Different Button designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ButtonDesign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum ButtonDesign { - /** - * attention type - */ - Attention = "Attention", - /** - * default type (no special styling) - */ - Default = "Default", - /** - * emphasized type - */ - Emphasized = "Emphasized", - /** - * reject style (red button) - */ - Negative = "Negative", - /** - * accept type (green button) - */ - Positive = "Positive", - /** - * transparent type - */ - Transparent = "Transparent", - } - /** - * Determines if the button has special form-related functionality. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ButtonType'. - * - * @since 1.120.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.120.0. This API is experimental and might change significantly. - */ - export enum ButtonType { - /** - * The button does not do anything special when inside a form - */ - Button = "Button", - /** - * The button acts as a reset button (resets a form) - */ - Reset = "Reset", - /** - * The button acts as a submit button (submits a form) - */ - Submit = "Submit", - } - /** - * Different Calendar selection mode. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'CalendarSelectionMode'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum CalendarSelectionMode { - /** - * Several dates can be selected - */ - Multiple = "Multiple", - /** - * A range defined by a start date and an end date can be selected - */ - Range = "Range", - /** - * Only one date can be selected at a time - */ - Single = "Single", - } - /** - * Different Carousel arrows placement. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'CarouselArrowsPlacement'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum CarouselArrowsPlacement { - /** - * Carousel arrows are placed on the sides of the current Carousel page. - */ - Content = "Content", - /** - * Carousel arrows are placed on the sides of the page indicator of the Carousel. - */ - Navigation = "Navigation", - } - /** - * Different Carousel page indicator styles. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'CarouselPageIndicatorStyle'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum CarouselPageIndicatorStyle { - /** - * The page indicator will be visualized as dots if there are fewer than 9 pages. If there are more pages, - * the page indicator will switch to displaying the current page and the total number of pages. (e.g. X - * of Y) - */ - Default = "Default", - /** - * The page indicator will display the current page and the total number of pages. (e.g. X of Y) - */ - Numeric = "Numeric", - } - /** - * Different filtering types of the ComboBox. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ComboBoxFilter'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum ComboBoxFilter { - /** - * Defines contains filtering. - */ - Contains = "Contains", - /** - * Removes any filtering applied while typing - */ - None = "None", - /** - * Defines filtering by starting symbol of item's text. - */ - StartsWith = "StartsWith", - /** - * Defines filtering by first symbol of each word of item's text. - */ - StartsWithPerTerm = "StartsWithPerTerm", - } - /** - * Different types of HasPopup. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'HasPopup'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum HasPopup { - /** - * Dialog popup type. - */ - Dialog = "Dialog", - /** - * Grid popup type. - */ - Grid = "Grid", - /** - * ListBox popup type. - */ - ListBox = "ListBox", - /** - * Menu popup type. - */ - Menu = "Menu", - /** - * Tree popup type. - */ - Tree = "Tree", - } - /** - * Interface for components that represent an avatar and may be slotted in numerous higher-order components - * such as `ui5-avatar-group` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IAvatar { - __implements__sap_ui_webc_main_IAvatar: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-breadcrumbs` as options - * - * @since 1.95.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.95.0. This API is experimental and might change significantly. - */ - export interface IBreadcrumbsItem { - __implements__sap_ui_webc_main_IBreadcrumbsItem: boolean; - } - - /** - * Interface for components that may be used as a button inside numerous higher-order components - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IButton { - __implements__sap_ui_webc_main_IButton: boolean; - } - - /** - * Interface for components that may be used as dates inside `ui5-calendar` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ICalendarDate { - __implements__sap_ui_webc_main_ICalendarDate: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-card` as header - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export interface ICardHeader { - __implements__sap_ui_webc_main_ICardHeader: boolean; - } - - /** - * Interface for components that may be used inside a `ui5-color-palette` or `ui5-color-palette-popover` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IColorPaletteItem { - __implements__sap_ui_webc_main_IColorPaletteItem: boolean; - } - - /** - * Interface for components that may be slotted inside a `ui5-combobox` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IComboBoxItem { - __implements__sap_ui_webc_main_IComboBoxItem: boolean; - } - - /** - * Different Icon semantic designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'IconDesign'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum IconDesign { - /** - * Contrast design - */ - Contrast = "Contrast", - /** - * Critical design - */ - Critical = "Critical", - /** - * Default design (brand design) - */ - Default = "Default", - /** - * info type - */ - Information = "Information", - /** - * Negative design - */ - Negative = "Negative", - /** - * Neutral design - */ - Neutral = "Neutral", - /** - * Design that indicates an icon which isn't interactive - */ - NonInteractive = "NonInteractive", - /** - * Positive design - */ - Positive = "Positive", - } - /** - * Interface for components that represent an icon, usable in numerous higher-order components - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IIcon { - __implements__sap_ui_webc_main_IIcon: boolean; - } - - /** - * Interface for components that represent an input, usable in numerous higher-order components - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IInput { - __implements__sap_ui_webc_main_IInput: boolean; - } - - /** - * Interface for components that represent a suggestion item, usable in `ui5-input` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IInputSuggestionItem { - __implements__sap_ui_webc_main_IInputSuggestionItem: boolean; - } - - /** - * Interface for components that may be slotted inside a `ui5-list` as items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IListItem { - __implements__sap_ui_webc_main_IListItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-menu` as items - * - * @since 1.102.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.102.0. This API is experimental and might change significantly. - */ - export interface IMenuItem { - __implements__sap_ui_webc_main_IMenuItem: boolean; - } - - /** - * Interface for components that may be slotted inside a `ui5-multi-combobox` as items - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IMultiComboBoxItem { - __implements__sap_ui_webc_main_IMultiComboBoxItem: boolean; - } - - /** - * Different input types. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'InputType'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum InputType { - /** - * Used for input fields that must contain an e-mail address. - */ - Email = "Email", - /** - * Defines a numeric input field. - */ - Number = "Number", - /** - * Defines a password field. - */ - Password = "Password", - /** - * Used for input fields that should contain a telephone number. - */ - Tel = "Tel", - /** - * Defines a one-line text input field: - */ - Text = "Text", - /** - * Used for input fields that should contain a URL address. - */ - URL = "URL", - } - /** - * Interface for components that may be slotted inside `ui5-segmented-button` as items - * - * @since 1.95.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.95.0. This API is experimental and might change significantly. - */ - export interface ISegmentedButtonItem { - __implements__sap_ui_webc_main_ISegmentedButtonItem: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-select-menu` as options - * - * @since 1.120.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.120.0. This API is experimental and might change significantly. - */ - export interface ISelectMenuOption { - __implements__sap_ui_webc_main_ISelectMenuOption: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-select` as options - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ISelectOption { - __implements__sap_ui_webc_main_ISelectOption: boolean; - } - - /** - * Interface for components that may be slotted inside `ui5-tabcontainer` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ITab { - __implements__sap_ui_webc_main_ITab: boolean; - } - - /** - * Interface for components that may be slotted inside a `ui5-table-row` as cells - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ITableCell { - __implements__sap_ui_webc_main_ITableCell: boolean; - } - - /** - * Interface for components that may be slotted inside a `ui5-table` as columns - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ITableColumn { - __implements__sap_ui_webc_main_ITableColumn: boolean; - } - - /** - * Interface for components that may be slotted inside a `ui5-table` as rows - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ITableRow { - __implements__sap_ui_webc_main_ITableRow: boolean; - } - - /** - * Interface for components that represent a token and are usable in components such as `ui5-multi-input` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface IToken { - __implements__sap_ui_webc_main_IToken: boolean; - } - - /** - * Interface for toolbar items for the purpose of `ui5-toolbar` - * - * @since 1.120.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.120.0. This API is experimental and might change significantly. - */ - export interface IToolbarItem { - __implements__sap_ui_webc_main_IToolbarItem: boolean; - } - - /** - * Interface for toolbar select items for the purpose of `ui5-toolbar-select` - * - * @since 1.120.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.120.0. This API is experimental and might change significantly. - */ - export interface IToolbarSelectOption { - __implements__sap_ui_webc_main_IToolbarSelectOption: boolean; - } - - /** - * Interface for tree items for the purpose of `ui5-tree` - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export interface ITreeItem { - __implements__sap_ui_webc_main_ITreeItem: boolean; - } - - /** - * Different link designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'LinkDesign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum LinkDesign { - /** - * default type (no special styling) - */ - Default = "Default", - /** - * emphasized type - */ - Emphasized = "Emphasized", - /** - * subtle type (appears as regular text, rather than a link) - */ - Subtle = "Subtle", - } - /** - * Different list growing modes. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ListGrowingMode'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum ListGrowingMode { - /** - * Component's "load-more" is fired upon pressing a "More" button. at the bottom. - */ - Button = "Button", - /** - * Component's growing is not enabled. - */ - None = "None", - /** - * Component's "load-more" is fired upon scroll. - */ - Scroll = "Scroll", - } - /** - * Different list item types. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ListItemType'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum ListItemType { - /** - * Indicates that the item is clickable via active feedback when item is pressed. - */ - Active = "Active", - /** - * Enables detail button of the list item that fires detail-click event. - */ - Detail = "Detail", - /** - * Indicates the list item does not have any active feedback when item is pressed. - */ - Inactive = "Inactive", - /** - * Enables the type of navigation, which is specified to add an arrow at the end of the items and fires - * navigate-click event. - */ - Navigation = "Navigation", - } - /** - * Different list modes. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ListMode'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum ListMode { - /** - * Delete mode (only one list item can be deleted via provided delete button) - */ - Delete = "Delete", - /** - * Multi selection mode (more than one list item can be selected). - */ - MultiSelect = "MultiSelect", - /** - * Default mode (no selection). - */ - None = "None", - /** - * Right-positioned single selection mode (only one list item can be selected). - */ - SingleSelect = "SingleSelect", - /** - * Selected item is highlighted and selection is changed upon arrow navigation (only one list item can be - * selected - this is always the focused item). - */ - SingleSelectAuto = "SingleSelectAuto", - /** - * Left-positioned single selection mode (only one list item can be selected). - */ - SingleSelectBegin = "SingleSelectBegin", - /** - * Selected item is highlighted but no selection element is visible (only one list item can be selected). - */ - SingleSelectEnd = "SingleSelectEnd", - } - /** - * Different types of list items separators. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ListSeparators'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum ListSeparators { - /** - * Separators between the items including the last and the first one. - */ - All = "All", - /** - * Separators between the items. Note: This enumeration depends on the theme. - */ - Inner = "Inner", - /** - * No item separators. - */ - None = "None", - } - /** - * MessageStrip designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'MessageStripDesign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum MessageStripDesign { - /** - * Message should be just an information - */ - Information = "Information", - /** - * Message is an error - */ - Negative = "Negative", - /** - * Message is a success message - */ - Positive = "Positive", - /** - * Message is a warning - */ - Warning = "Warning", - } - /** - * Panel accessible roles. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'PanelAccessibleRole'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum PanelAccessibleRole { - /** - * Represents the ARIA role "complementary". A section of the page, designed to be complementary to the - * main content at a similar level in the DOM hierarchy. - */ - Complementary = "Complementary", - /** - * Represents the ARIA role "Form". A landmark region that contains a collection of items and objects that, - * as a whole, create a form. - */ - Form = "Form", - /** - * Represents the ARIA role "Region". A section of a page, that is important enough to be included in a - * page summary or table of contents. - */ - Region = "Region", - } - /** - * Popover horizontal align types. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'PopoverHorizontalAlign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum PopoverHorizontalAlign { - /** - * Popover is centered. - */ - Center = "Center", - /** - * Popover is aligned with the left side of the target. When direction is RTL, it is right aligned. - */ - Left = "Left", - /** - * Popover is aligned with the right side of the target. When direction is RTL, it is left aligned. - */ - Right = "Right", - /** - * Popover is stretched. - */ - Stretch = "Stretch", - } - /** - * Popover placement types. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'PopoverPlacementType'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum PopoverPlacementType { - /** - * Popover will be placed at the bottom of the reference element. - */ - Bottom = "Bottom", - /** - * Popover will be placed at the left side of the reference element. - */ - Left = "Left", - /** - * Popover will be placed at the right side of the reference element. - */ - Right = "Right", - /** - * Popover will be placed at the top of the reference element. - */ - Top = "Top", - } - /** - * Popover vertical align types. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'PopoverVerticalAlign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum PopoverVerticalAlign { - /** - * Popover will be placed at the bottom of the reference control. - */ - Bottom = "Bottom", - - Center = "Center", - /** - * Popover will be streched - */ - Stretch = "Stretch", - /** - * Popover will be placed at the top of the reference control. - */ - Top = "Top", - } - /** - * Popup accessible roles. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'PopupAccessibleRole'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum PopupAccessibleRole { - /** - * Represents the ARIA role "alertdialog". - */ - AlertDialog = "AlertDialog", - /** - * Represents the ARIA role "dialog". - */ - Dialog = "Dialog", - /** - * Represents no ARIA role. - */ - None = "None", - } - /** - * Different types of Priority. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'Priority'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum Priority { - /** - * High priority. - */ - High = "High", - /** - * Low priority. - */ - Low = "Low", - /** - * Medium priority. - */ - Medium = "Medium", - /** - * Default, none priority. - */ - None = "None", - } - /** - * Different SegmentedButton modes. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'SegmentedButtonMode'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum SegmentedButtonMode { - /** - * Multiple items can be selected at a time. All items can be deselected. - */ - MultiSelect = "MultiSelect", - /** - * There is always one selected. Selecting one deselects the previous one. - */ - SingleSelect = "SingleSelect", - } - /** - * Different types of SemanticColor. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'SemanticColor'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum SemanticColor { - /** - * Critical color - */ - Critical = "Critical", - /** - * Default color (brand color) - */ - Default = "Default", - /** - * Negative color - */ - Negative = "Negative", - /** - * Neutral color. - */ - Neutral = "Neutral", - /** - * Positive color - */ - Positive = "Positive", - } - /** - * Different types of Switch designs. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'SwitchDesign'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum SwitchDesign { - /** - * Defines the Switch as Graphical - */ - Graphical = "Graphical", - /** - * Defines the Switch as Textual - */ - Textual = "Textual", - } - /** - * Background design for the header and content of TabContainer. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TabContainerBackgroundDesign'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum TabContainerBackgroundDesign { - /** - * A Solid background color. - */ - Solid = "Solid", - /** - * A Translucent background color. - */ - Translucent = "Translucent", - /** - * A Transparent background color. - */ - Transparent = "Transparent", - } - /** - * Tab layout of TabContainer. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TabLayout'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum TabLayout { - /** - * Inline type, the tab "main text" and "additionalText" are displayed horizotally. - */ - Inline = "Inline", - /** - * Standard type, the tab "main text" and "additionalText" are displayed vertically. - */ - Standard = "Standard", - } - /** - * Table cell popin display. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TableColumnPopinDisplay'. - * - * @since 1.115.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.115.0. This API is experimental and might change significantly. - */ - export enum TableColumnPopinDisplay { - /** - * default type - */ - Block = "Block", - /** - * inline type (the title and value are displayed on the same line) - */ - Inline = "Inline", - } - /** - * Different table growing modes. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TableGrowingMode'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum TableGrowingMode { - /** - * Component `load-more` is fired upon pressing a "More" button at the bottom. - */ - Button = "Button", - /** - * Component growing is not enabled. - */ - None = "None", - /** - * Component `load-more` is fired upon scroll. - */ - Scroll = "Scroll", - } - /** - * Different table modes. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TableMode'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum TableMode { - /** - * Multi selection mode (more than one table row can be selected). - */ - MultiSelect = "MultiSelect", - /** - * Default mode (no selection). - */ - None = "None", - /** - * Single selection mode (only one table row can be selected). - */ - SingleSelect = "SingleSelect", - } - /** - * Different table row types. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TableRowType'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum TableRowType { - /** - * Indicates that the table row is clickable via active feedback when item is pressed. - */ - Active = "Active", - /** - * Indicates that the table row does not have any active feedback when item is pressed. - */ - Inactive = "Inactive", - } - /** - * Tabs overflow mode in TabContainer. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TabsOverflowMode'. - * - * @since 1.99.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.99.0. This API is experimental and might change significantly. - */ - export enum TabsOverflowMode { - /** - * End type is used if there should be only one overflow with hidden the tabs at the end of the tab container. - */ - End = "End", - /** - * StartAndEnd type is used if there should be two overflows on both ends of the tab container. - */ - StartAndEnd = "StartAndEnd", - } - /** - * Different types of Title level. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'TitleLevel'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum TitleLevel { - /** - * Renders `h1` tag. - */ - H1 = "H1", - /** - * Renders `h2` tag. - */ - H2 = "H2", - /** - * Renders `h3` tag. - */ - H3 = "H3", - /** - * Renders `h4` tag. - */ - H4 = "H4", - /** - * Renders `h5` tag. - */ - H5 = "H5", - /** - * Renders `h6` tag. - */ - H6 = "H6", - } - /** - * Toast placement. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ToastPlacement'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum ToastPlacement { - /** - * Toast is placed at the `BottomCenter` position of its container. Default placement (no selection) - */ - BottomCenter = "BottomCenter", - /** - * Toast is placed at the `BottomEnd` position of its container. - */ - BottomEnd = "BottomEnd", - /** - * Toast is placed at the `BottomStart` position of its container. - */ - BottomStart = "BottomStart", - /** - * Toast is placed at the `MiddleCenter` position of its container. - */ - MiddleCenter = "MiddleCenter", - /** - * Toast is placed at the `MiddleEnd` position of its container. - */ - MiddleEnd = "MiddleEnd", - /** - * Toast is placed at the `MiddleStart` position of its container. - */ - MiddleStart = "MiddleStart", - /** - * Toast is placed at the `TopCenter` position of its container. - */ - TopCenter = "TopCenter", - /** - * Toast is placed at the `TopEnd` position of its container. - */ - TopEnd = "TopEnd", - /** - * Toast is placed at the `TopStart` position of its container. - */ - TopStart = "TopStart", - } - /** - * Defines which direction the items of ui5-toolbar will be aligned. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ToolbarAlign'. - * - * @since 1.120.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.120.0. This API is experimental and might change significantly. - */ - export enum ToolbarAlign { - /** - * Toolbar items are situated at the `end` of the Toolbar - */ - End = "End", - /** - * Toolbar items are situated at the `start` of the Toolbar - */ - Start = "Start", - } - /** - * Defines the priority of the toolbar item to go inside overflow popover. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'ToolbarItemOverflowBehavior'. - * - * @since 1.120.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.120.0. This API is experimental and might change significantly. - */ - export enum ToolbarItemOverflowBehavior { - AlwaysOverflow = "AlwaysOverflow", - /** - * The item is presented inside the toolbar and goes in the popover, when there is not enough space. - */ - Default = "Default", - /** - * When set, the item will never go to the overflow popover. - */ - NeverOverflow = "NeverOverflow", - } - /** - * Different types of wrapping. - * - * This enum is part of the 'sap/ui/webc/main/library' module export and must be accessed by the property - * 'WrappingType'. - * - * @since 1.92.0 - * @deprecated As of version 1.120. because it is part of the deprecated package sap.ui.webc.main - * @experimental As of version 1.92.0. This API is experimental and might change significantly. - */ - export enum WrappingType { - /** - * The text will be truncated with an ellipsis. - */ - None = "None", - /** - * The text will wrap. The words will not be broken based on hyphenation. - */ - Normal = "Normal", - } -} - -declare module "sap/ui/webc/main/Avatar" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - IAvatar, - AvatarColorScheme, - AvatarShape, - AvatarSize, - } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * An image-like component that has different display options for representing images and icons in different - * shapes and sizes, depending on the use case. - * - * The shape can be circular or square. There are several predefined sizes, as well as an option to set - * a custom size. - * - * - * - * Keyboard Handling: - * - * - * - [SPACE, ENTER, RETURN] - Fires the `click` event if the `interactive` property is set to true. - * - [SHIFT] - If [SPACE] is pressed, pressing [SHIFT] releases the component without triggering the click - * event. - * - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Avatar extends WebComponent implements IAvatar { - __implements__sap_ui_webc_main_IAvatar: boolean; - /** - * Constructor for a new `Avatar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $AvatarSettings - ); - /** - * Constructor for a new `Avatar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $AvatarSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Avatar with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Avatar. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Avatar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Avatar` itself. - * - * Fired when the user clicks the control - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Avatar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Avatar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Avatar` itself. - * - * Fired when the user clicks the control - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Avatar` itself - */ - oListener?: object - ): this; - /** - * Destroys the badge in the aggregation {@link #getBadge badge}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyBadge(): this; - /** - * Destroys the image in the aggregation {@link #getImage image}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyImage(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.Avatar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. If not provided a default text alternative will be set, - * if present. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets content of aggregation {@link #getBadge badge}. - * - * Defines the optional badge that will be used for visual affordance. **Note:** While the slot allows for - * custom badges, to achieve the Fiori design, please use `sap.ui.webc.main.Badge` with `sap.ui.webc.main.Icon` - * in the corresponding `icon` slot, without text nodes. - * - * Example: - * - * - * - * - * - * - */ - getBadge(): Control; - /** - * Gets current value of property {@link #getColorScheme colorScheme}. - * - * Defines the background color of the desired image. - * - * Available options are: - * - `Accent1` - * - `Accent2` - * - `Accent3` - * - `Accent4` - * - `Accent5` - * - `Accent6` - * - `Accent7` - * - `Accent8` - * - `Accent9` - * - `Accent10` - * - `Placeholder` - * - * Default value is `Accent6`. - * - * - * @returns Value of property `colorScheme` - */ - getColorScheme(): AvatarColorScheme; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getFallbackIcon fallbackIcon}. - * - * Defines the name of the fallback icon, which should be displayed in the following cases: - * - If the initials are not valid (more than 3 letters, unsupported languages or empty initials). - * - If there are three initials and they do not fit in the shape (e.g. WWW for some of the sizes). - * - If the image src is wrong. - * - * - * **Note:** If not set, a default fallback icon "employee" is displayed. - * **Note:** You should import the desired icon first, then use its name as "fallback-icon". - * - * import "@ui5/webcomponents-icons/dist/{icon_name}.js" - * - * ```javascript - * ``` - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `fallbackIcon` - */ - getFallbackIcon(): string; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the name of the UI5 Icon, that will be displayed. - * **Note:** If `image` slot is provided, the property will be ignored. - * **Note:** You should import the desired icon first, then use its name as "icon". - * - * import "@ui5/webcomponents-icons/dist/{icon_name}.js" - * - * ```javascript - * ``` - * - * **Note:** If no icon or an empty one is provided, by default the "employee" icon should be displayed. - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets content of aggregation {@link #getImage image}. - * - * Receives the desired `` tag - * - * **Note:** If you experience flickering of the provided image, you can hide the component until it is - * being defined with the following CSS: ` ui5-avatar:not(:defined) { visibility: hidden; - * } ` - */ - getImage(): Control; - /** - * Gets current value of property {@link #getInitials initials}. - * - * Defines the displayed initials. - * Up to three Latin letters can be displayed as initials. - * - * Default value is `empty string`. - * - * - * @returns Value of property `initials` - */ - getInitials(): string; - /** - * Gets current value of property {@link #getInteractive interactive}. - * - * Defines if the avatar is interactive (focusable and pressable). **Note:** This property won't have effect - * if the `disabled` property is set to `true`. - * - * Default value is `false`. - * - * - * @returns Value of property `interactive` - */ - getInteractive(): boolean; - /** - * Gets current value of property {@link #getShape shape}. - * - * Defines the shape of the component. - * - * Available options are: - * - `Circle` - * - `Square` - * - * Default value is `Circle`. - * - * - * @returns Value of property `shape` - */ - getShape(): AvatarShape; - /** - * Gets current value of property {@link #getSize size}. - * - * Defines predefined size of the component. - * - * Available options are: - * - `XS` - * - `S` - * - `M` - * - `L` - * - `XL` - * - * Default value is `S`. - * - * - * @returns Value of property `size` - */ - getSize(): AvatarSize; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. If not provided a default text alternative will be set, - * if present. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets the aggregated {@link #getBadge badge}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBadge( - /** - * The badge to set - */ - oBadge: Control - ): this; - /** - * Sets a new value for property {@link #getColorScheme colorScheme}. - * - * Defines the background color of the desired image. - * - * Available options are: - * - `Accent1` - * - `Accent2` - * - `Accent3` - * - `Accent4` - * - `Accent5` - * - `Accent6` - * - `Accent7` - * - `Accent8` - * - `Accent9` - * - `Accent10` - * - `Placeholder` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Accent6`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setColorScheme( - /** - * New value for property `colorScheme` - */ - sColorScheme?: AvatarColorScheme | keyof typeof AvatarColorScheme - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getFallbackIcon fallbackIcon}. - * - * Defines the name of the fallback icon, which should be displayed in the following cases: - * - If the initials are not valid (more than 3 letters, unsupported languages or empty initials). - * - If there are three initials and they do not fit in the shape (e.g. WWW for some of the sizes). - * - If the image src is wrong. - * - * - * **Note:** If not set, a default fallback icon "employee" is displayed. - * **Note:** You should import the desired icon first, then use its name as "fallback-icon". - * - * import "@ui5/webcomponents-icons/dist/{icon_name}.js" - * - * ```javascript - * ``` - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFallbackIcon( - /** - * New value for property `fallbackIcon` - */ - sFallbackIcon?: string - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the name of the UI5 Icon, that will be displayed. - * **Note:** If `image` slot is provided, the property will be ignored. - * **Note:** You should import the desired icon first, then use its name as "icon". - * - * import "@ui5/webcomponents-icons/dist/{icon_name}.js" - * - * ```javascript - * ``` - * - * **Note:** If no icon or an empty one is provided, by default the "employee" icon should be displayed. - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets the aggregated {@link #getImage image}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setImage( - /** - * The image to set - */ - oImage: Control - ): this; - /** - * Sets a new value for property {@link #getInitials initials}. - * - * Defines the displayed initials. - * Up to three Latin letters can be displayed as initials. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInitials( - /** - * New value for property `initials` - */ - sInitials?: string - ): this; - /** - * Sets a new value for property {@link #getInteractive interactive}. - * - * Defines if the avatar is interactive (focusable and pressable). **Note:** This property won't have effect - * if the `disabled` property is set to `true`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInteractive( - /** - * New value for property `interactive` - */ - bInteractive?: boolean - ): this; - /** - * Sets a new value for property {@link #getShape shape}. - * - * Defines the shape of the component. - * - * Available options are: - * - `Circle` - * - `Square` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Circle`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShape( - /** - * New value for property `shape` - */ - sShape?: AvatarShape | keyof typeof AvatarShape - ): this; - /** - * Sets a new value for property {@link #getSize size}. - * - * Defines predefined size of the component. - * - * Available options are: - * - `XS` - * - `S` - * - `M` - * - `L` - * - `XL` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `S`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSize( - /** - * New value for property `size` - */ - sSize?: AvatarSize | keyof typeof AvatarSize - ): this; - } - /** - * Describes the settings that can be provided to the Avatar constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $AvatarSettings extends $WebComponentSettings { - /** - * Defines the text alternative of the component. If not provided a default text alternative will be set, - * if present. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the background color of the desired image. - * - * Available options are: - * - `Accent1` - * - `Accent2` - * - `Accent3` - * - `Accent4` - * - `Accent5` - * - `Accent6` - * - `Accent7` - * - `Accent8` - * - `Accent9` - * - `Accent10` - * - `Placeholder` - */ - colorScheme?: - | (AvatarColorScheme | keyof typeof AvatarColorScheme) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the name of the fallback icon, which should be displayed in the following cases: - * - If the initials are not valid (more than 3 letters, unsupported languages or empty initials). - * - If there are three initials and they do not fit in the shape (e.g. WWW for some of the sizes). - * - If the image src is wrong. - * - * - * **Note:** If not set, a default fallback icon "employee" is displayed. - * **Note:** You should import the desired icon first, then use its name as "fallback-icon". - * - * import "@ui5/webcomponents-icons/dist/{icon_name}.js" - * - * ```javascript - * ``` - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - fallbackIcon?: string | PropertyBindingInfo; - - /** - * Defines the name of the UI5 Icon, that will be displayed. - * **Note:** If `image` slot is provided, the property will be ignored. - * **Note:** You should import the desired icon first, then use its name as "icon". - * - * import "@ui5/webcomponents-icons/dist/{icon_name}.js" - * - * ```javascript - * ``` - * - * **Note:** If no icon or an empty one is provided, by default the "employee" icon should be displayed. - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the displayed initials. - * Up to three Latin letters can be displayed as initials. - */ - initials?: string | PropertyBindingInfo; - - /** - * Defines if the avatar is interactive (focusable and pressable). **Note:** This property won't have effect - * if the `disabled` property is set to `true`. - */ - interactive?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the shape of the component. - * - * Available options are: - * - `Circle` - * - `Square` - */ - shape?: - | (AvatarShape | keyof typeof AvatarShape) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines predefined size of the component. - * - * Available options are: - * - `XS` - * - `S` - * - `M` - * - `L` - * - `XL` - */ - size?: - | (AvatarSize | keyof typeof AvatarSize) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the optional badge that will be used for visual affordance. **Note:** While the slot allows for - * custom badges, to achieve the Fiori design, please use `sap.ui.webc.main.Badge` with `sap.ui.webc.main.Icon` - * in the corresponding `icon` slot, without text nodes. - * - * Example: - * - * - * - * - * - * - */ - badge?: Control; - - /** - * Receives the desired `` tag - * - * **Note:** If you experience flickering of the provided image, you can hide the component until it is - * being defined with the following CSS: ` ui5-avatar:not(:defined) { visibility: hidden; - * } ` - */ - image?: Control; - - /** - * Fired when the user clicks the control - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the Avatar#click event. - */ - export interface Avatar$ClickEventParameters {} - - /** - * Event object of the Avatar#click event. - */ - export type Avatar$ClickEvent = Event; -} - -declare module "sap/ui/webc/main/AvatarGroup" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IAvatar, AvatarGroupType } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import Control from "sap/ui/core/Control"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * Displays a group of avatars arranged horizontally. It is useful to visually showcase a group of related - * avatars, such as, project team members or employees. - * - * The component allows you to display the avatars in different sizes, depending on your use case. - * - * The `AvatarGroup` component has two group types: - * - `Group` type: The avatars are displayed as partially overlapped on top of each other and the entire - * group has one click/tap area. - * - `Individual` type: The avatars are displayed side-by-side and each avatar has its own click/tap area. - * - * - * Responsive Behavior: - * - * When the available space is less than the width required to display all avatars, an overflow visualization - * appears as a button placed at the end with the same shape and size as the avatars. The visualization - * displays the number of avatars that have overflowed and are not currently visible. - * - * Usage: - * - * Use the `AvatarGroup` if: - * - You want to display a group of avatars. - * - You want to display several avatars which have something in common. - * - * Do not use the `AvatarGroup` if: - * - You want to display a single avatar. - * - You want to display a gallery for simple images. - * - You want to use it for other visual content than avatars. - * - * Keyboard Handling: The component provides advanced keyboard handling. When focused, the user can use - * the following keyboard shortcuts in order to perform a navigation: - * - * - * `type` Individual: - * - * - * - * - [TAB] - Move focus to the overflow button - * - [LEFT] - Navigate one avatar to the left - * - [RIGHT] - Navigate one avatar to the right - * - [HOME] - Navigate to the first avatar - * - [END] - Navigate to the last avatar - * - [SPACE],[ENTER],[RETURN] - Trigger `ui5-click` event - * `type` Group: - * - * - * - * - [TAB] - Move focus to the next interactive element after the component - * - [SPACE],[ENTER],[RETURN] - Trigger `ui5-click` event - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class AvatarGroup extends WebComponent { - /** - * Constructor for a new `AvatarGroup`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $AvatarGroupSettings - ); - /** - * Constructor for a new `AvatarGroup`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $AvatarGroupSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.AvatarGroup with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.AvatarGroup. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IAvatar - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.AvatarGroup`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.AvatarGroup` itself. - * - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: AvatarGroup$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.AvatarGroup` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.AvatarGroup`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.AvatarGroup` itself. - * - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: AvatarGroup$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.AvatarGroup` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:overflow overflow} event of this `sap.ui.webc.main.AvatarGroup`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.AvatarGroup` itself. - * - * Fired when the count of visible `sap.ui.webc.main.Avatar` elements in the component has changed - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOverflow( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.AvatarGroup` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:overflow overflow} event of this `sap.ui.webc.main.AvatarGroup`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.AvatarGroup` itself. - * - * Fired when the count of visible `sap.ui.webc.main.Avatar` elements in the component has changed - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOverflow( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.AvatarGroup` itself - */ - oListener?: object - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Destroys the overflowButton in the aggregation {@link #getOverflowButton overflowButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyOverflowButton(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.AvatarGroup`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: AvatarGroup$ClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:overflow overflow} event of this `sap.ui.webc.main.AvatarGroup`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachOverflow( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: AvatarGroup$ClickEventParameters - ): this; - /** - * Fires event {@link #event:overflow overflow} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireOverflow( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Returns an array containing the `AvatarColorScheme` values that correspond to the avatars in the component. - */ - getColorScheme(): void; - /** - * Returns an array containing the `ui5-avatar` instances that are currently not displayed due to lack of - * space. - */ - getHiddenItems(): void; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the component. Use the `sap.ui.webc.main.Avatar` component as an item. - * - * **Note:** The UX guidelines recommends using avatars with "Circle" shape. Moreover, if you use avatars - * with "Square" shape, there will be visual inconsistency as the built-in overflow action has "Circle" - * shape. - */ - getItems(): IAvatar[]; - /** - * Gets content of aggregation {@link #getOverflowButton overflowButton}. - * - * Defines the overflow button of the component. **Note:** We recommend using the `sap.ui.webc.main.Button` - * component. - * - * **Note:** If this slot is not used, the component will display the built-in overflow button. - */ - getOverflowButton(): Control; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the mode of the `AvatarGroup`. - * - * Available options are: - * - `Group` - * - `Individual` - * - * Default value is `Group`. - * - * - * @returns Value of property `type` - */ - getType(): AvatarGroupType; - /** - * Checks for the provided `sap.ui.webc.main.IAvatar` in the aggregation {@link #getItems items}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IAvatar - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IAvatar, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IAvatar[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IAvatar - ): IAvatar | null; - /** - * Sets the aggregated {@link #getOverflowButton overflowButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOverflowButton( - /** - * The overflowButton to set - */ - oOverflowButton: Control - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the mode of the `AvatarGroup`. - * - * Available options are: - * - `Group` - * - `Individual` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Group`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: AvatarGroupType | keyof typeof AvatarGroupType - ): this; - } - /** - * Describes the settings that can be provided to the AvatarGroup constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $AvatarGroupSettings extends $WebComponentSettings { - /** - * Defines the mode of the `AvatarGroup`. - * - * Available options are: - * - `Group` - * - `Individual` - */ - type?: - | (AvatarGroupType | keyof typeof AvatarGroupType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the items of the component. Use the `sap.ui.webc.main.Avatar` component as an item. - * - * **Note:** The UX guidelines recommends using avatars with "Circle" shape. Moreover, if you use avatars - * with "Square" shape, there will be visual inconsistency as the built-in overflow action has "Circle" - * shape. - */ - items?: IAvatar[] | IAvatar | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the overflow button of the component. **Note:** We recommend using the `sap.ui.webc.main.Button` - * component. - * - * **Note:** If this slot is not used, the component will display the built-in overflow button. - */ - overflowButton?: Control; - - /** - * Fired when the component is activated either with a click/tap or by using the Enter or Space key. - */ - click?: (oEvent: AvatarGroup$ClickEvent) => void; - - /** - * Fired when the count of visible `sap.ui.webc.main.Avatar` elements in the component has changed - */ - overflow?: (oEvent: Event) => void; - } - - /** - * Parameters of the AvatarGroup#click event. - */ - export interface AvatarGroup$ClickEventParameters { - /** - * The DOM ref of the clicked item. - */ - targetRef?: HTMLElement; - - /** - * indicates if the overflow button is clicked - */ - overflowButtonClicked?: boolean; - } - - /** - * Event object of the AvatarGroup#click event. - */ - export type AvatarGroup$ClickEvent = Event< - AvatarGroup$ClickEventParameters, - AvatarGroup - >; - - /** - * Parameters of the AvatarGroup#overflow event. - */ - export interface AvatarGroup$OverflowEventParameters {} - - /** - * Event object of the AvatarGroup#overflow event. - */ - export type AvatarGroup$OverflowEvent = Event< - AvatarGroup$OverflowEventParameters, - AvatarGroup - >; -} - -declare module "sap/ui/webc/main/Badge" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IIcon } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Badge` is a small non-interactive component which contains text information and - * color chosen from a list of predefined color schemes. It serves the purpose to attract the user attention - * to some piece of information (state, quantity, condition, etc.). - * - * Usage Guidelines: - * - If the text is longer than the width of the component, it doesn’t wrap, it shows ellipsis. - * - When truncated, the full text is not visible, therefore, it’s recommended to make more space for - * longer texts to be fully displayed. - * - Colors are not semantic and have no visual representation in High Contrast Black (sap_belize_hcb) - * theme. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Badge extends WebComponent { - /** - * Constructor for a new `Badge`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $BadgeSettings - ); - /** - * Constructor for a new `Badge`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $BadgeSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Badge with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Badge. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some icon to the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addIcon( - /** - * The icon to add; if empty, nothing is inserted - */ - oIcon: IIcon - ): this; - /** - * Destroys all the icon in the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyIcon(): this; - /** - * Gets current value of property {@link #getColorScheme colorScheme}. - * - * Defines the color scheme of the component. There are 10 predefined schemes. To use one you can set a - * number from `"1"` to `"10"`. The `colorScheme` `"1"` will be set by default. - * - * **Note:** Color schemes have no visual representation in High Contrast Black (sap_belize_hcb) theme. - * - * Default value is `"1"`. - * - * - * @returns Value of property `colorScheme` - */ - getColorScheme(): string; - /** - * Gets content of aggregation {@link #getIcon icon}. - * - * Defines the icon to be displayed in the component. - */ - getIcon(): IIcon[]; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Checks for the provided `sap.ui.webc.main.IIcon` in the aggregation {@link #getIcon icon}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfIcon( - /** - * The icon whose index is looked for - */ - oIcon: IIcon - ): int; - /** - * Inserts a icon into the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertIcon( - /** - * The icon to insert; if empty, nothing is inserted - */ - oIcon: IIcon, - /** - * The `0`-based index the icon should be inserted at; for a negative value of `iIndex`, the icon is inserted - * at position 0; for a value greater than the current size of the aggregation, the icon is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getIcon icon}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllIcon(): IIcon[]; - /** - * Removes a icon from the aggregation {@link #getIcon icon}. - * - * - * @returns The removed icon or `null` - */ - removeIcon( - /** - * The icon to remove or its index or id - */ - vIcon: int | string | IIcon - ): IIcon | null; - /** - * Sets a new value for property {@link #getColorScheme colorScheme}. - * - * Defines the color scheme of the component. There are 10 predefined schemes. To use one you can set a - * number from `"1"` to `"10"`. The `colorScheme` `"1"` will be set by default. - * - * **Note:** Color schemes have no visual representation in High Contrast Black (sap_belize_hcb) theme. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `"1"`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setColorScheme( - /** - * New value for property `colorScheme` - */ - sColorScheme?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the Badge constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $BadgeSettings extends $WebComponentSettings { - /** - * Defines the color scheme of the component. There are 10 predefined schemes. To use one you can set a - * number from `"1"` to `"10"`. The `colorScheme` `"1"` will be set by default. - * - * **Note:** Color schemes have no visual representation in High Contrast Black (sap_belize_hcb) theme. - */ - colorScheme?: string | PropertyBindingInfo; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the icon to be displayed in the component. - */ - icon?: IIcon[] | IIcon | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/Breadcrumbs" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - IBreadcrumbsItem, - BreadcrumbsDesign, - BreadcrumbsSeparatorStyle, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: Enables users to navigate between items by providing a list of links to previous steps in the - * user's navigation path. It helps the user to be aware of their location within the application and allows - * faster navigation. - * - * The last three steps can be accessed as links directly, while the remaining links prior to them are - * available in a drop-down menu. - * - * You can choose the type of separator to be used from a number of predefined options. - * - * Keyboard Handling: The `sap.ui.webc.main.Breadcrumbs` provides advanced keyboard handling. - * - * - * - * - [F4, ALT+UP, ALT+DOWN, SPACE, ENTER] - If the dropdown arrow is focused - opens/closes the drop-down. - * - * - [SPACE, ENTER] - Activates the focused item and triggers the `item-click` event. - * - [ESC] - Closes the drop-down. - * - [LEFT] - If the drop-down is closed - navigates one item to the left. - * - [RIGHT] - If the drop-down is closed - navigates one item to the right. - * - [UP] - If the drop-down is open - moves focus to the next item. - * - [DOWN] - If the drop-down is open - moves focus to the previous item. - * - [HOME] - Navigates to the first item. - * - [END] - Navigates to the last item. - * - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class Breadcrumbs extends WebComponent { - /** - * Constructor for a new `Breadcrumbs`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $BreadcrumbsSettings - ); - /** - * Constructor for a new `Breadcrumbs`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $BreadcrumbsSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Breadcrumbs with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Breadcrumbs. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IBreadcrumbsItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Breadcrumbs`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Breadcrumbs` itself. - * - * Fires when a `BreadcrumbsItem` is clicked. **Note:** You can prevent browser location change by calling - * `event.preventDefault()`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Breadcrumbs$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Breadcrumbs` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Breadcrumbs`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Breadcrumbs` itself. - * - * Fires when a `BreadcrumbsItem` is clicked. **Note:** You can prevent browser location change by calling - * `event.preventDefault()`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Breadcrumbs$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Breadcrumbs` itself - */ - oListener?: object - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Breadcrumbs`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Breadcrumbs$ItemClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:itemClick itemClick} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireItemClick( - /** - * Parameters to pass along with the event - */ - mParameters?: Breadcrumbs$ItemClickEventParameters - ): boolean; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the visual indication and behavior of the breadcrumbs. Available options are `Standard` (by default) - * and `NoCurrentPage`. - * - * **Note:** The `Standard` breadcrumbs show the current page as the last item in the trail. The last item - * contains only plain text and is not a link. - * - * Default value is `Standard`. - * - * - * @returns Value of property `design` - */ - getDesign(): BreadcrumbsDesign; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the component items. - * - * - * - * **Note:** Use the `sap.ui.webc.main.BreadcrumbsItem` component to define the desired items. - */ - getItems(): IBreadcrumbsItem[]; - /** - * Gets current value of property {@link #getSeparatorStyle separatorStyle}. - * - * Determines the visual style of the separator between the breadcrumb items. - * - * - * - * Available options are: - * - `Slash` - * - `BackSlash` - * - `DoubleBackSlash` - * - `DoubleGreaterThan` - * - `DoubleSlash` - * - `GreaterThan` - * - * Default value is `Slash`. - * - * - * @returns Value of property `separatorStyle` - */ - getSeparatorStyle(): BreadcrumbsSeparatorStyle; - /** - * Checks for the provided `sap.ui.webc.main.IBreadcrumbsItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IBreadcrumbsItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IBreadcrumbsItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IBreadcrumbsItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IBreadcrumbsItem - ): IBreadcrumbsItem | null; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the visual indication and behavior of the breadcrumbs. Available options are `Standard` (by default) - * and `NoCurrentPage`. - * - * **Note:** The `Standard` breadcrumbs show the current page as the last item in the trail. The last item - * contains only plain text and is not a link. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Standard`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: BreadcrumbsDesign | keyof typeof BreadcrumbsDesign - ): this; - /** - * Sets a new value for property {@link #getSeparatorStyle separatorStyle}. - * - * Determines the visual style of the separator between the breadcrumb items. - * - * - * - * Available options are: - * - `Slash` - * - `BackSlash` - * - `DoubleBackSlash` - * - `DoubleGreaterThan` - * - `DoubleSlash` - * - `GreaterThan` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Slash`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSeparatorStyle( - /** - * New value for property `separatorStyle` - */ - sSeparatorStyle?: - | BreadcrumbsSeparatorStyle - | keyof typeof BreadcrumbsSeparatorStyle - ): this; - } - /** - * Describes the settings that can be provided to the Breadcrumbs constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $BreadcrumbsSettings extends $WebComponentSettings { - /** - * Defines the visual indication and behavior of the breadcrumbs. Available options are `Standard` (by default) - * and `NoCurrentPage`. - * - * **Note:** The `Standard` breadcrumbs show the current page as the last item in the trail. The last item - * contains only plain text and is not a link. - */ - design?: - | (BreadcrumbsDesign | keyof typeof BreadcrumbsDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines the visual style of the separator between the breadcrumb items. - * - * - * - * Available options are: - * - `Slash` - * - `BackSlash` - * - `DoubleBackSlash` - * - `DoubleGreaterThan` - * - `DoubleSlash` - * - `GreaterThan` - */ - separatorStyle?: - | (BreadcrumbsSeparatorStyle | keyof typeof BreadcrumbsSeparatorStyle) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the component items. - * - * - * - * **Note:** Use the `sap.ui.webc.main.BreadcrumbsItem` component to define the desired items. - */ - items?: - | IBreadcrumbsItem[] - | IBreadcrumbsItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fires when a `BreadcrumbsItem` is clicked. **Note:** You can prevent browser location change by calling - * `event.preventDefault()`. - */ - itemClick?: (oEvent: Breadcrumbs$ItemClickEvent) => void; - } - - /** - * Parameters of the Breadcrumbs#itemClick event. - */ - export interface Breadcrumbs$ItemClickEventParameters { - /** - * The clicked item. - */ - item?: HTMLElement; - - /** - * Returns whether the "ALT" key was pressed when the event was triggered. - */ - altKey?: boolean; - - /** - * Returns whether the "CTRL" key was pressed when the event was triggered. - */ - ctrlKey?: boolean; - - /** - * Returns whether the "META" key was pressed when the event was triggered. - */ - metaKey?: boolean; - - /** - * Returns whether the "SHIFT" key was pressed when the event was triggered. - */ - shiftKey?: boolean; - } - - /** - * Event object of the Breadcrumbs#itemClick event. - */ - export type Breadcrumbs$ItemClickEvent = Event< - Breadcrumbs$ItemClickEventParameters, - Breadcrumbs - >; -} - -declare module "sap/ui/webc/main/BreadcrumbsItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IBreadcrumbsItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.BreadcrumbsItem` component defines the content of an item in `sap.ui.webc.main.Breadcrumbs`. - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class BreadcrumbsItem - extends WebComponent - implements IBreadcrumbsItem - { - __implements__sap_ui_webc_main_IBreadcrumbsItem: boolean; - /** - * Constructor for a new `BreadcrumbsItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $BreadcrumbsItemSettings - ); - /** - * Constructor for a new `BreadcrumbsItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $BreadcrumbsItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.BreadcrumbsItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.BreadcrumbsItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the item. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getHref href}. - * - * Defines the link href. - * - * **Note:** Standard hyperlink behavior is supported. - * - * Default value is `empty string`. - * - * - * @returns Value of property `href` - */ - getHref(): string; - /** - * Gets current value of property {@link #getTarget target}. - * - * Defines the link target. - * - * Available options are: - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * Note: This property must only be used when the `href` property is set. - * - * Default value is `undefined`. - * - * - * @returns Value of property `target` - */ - getTarget(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getHref href}. - * - * Defines the link href. - * - * **Note:** Standard hyperlink behavior is supported. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHref( - /** - * New value for property `href` - */ - sHref?: string - ): this; - /** - * Sets a new value for property {@link #getTarget target}. - * - * Defines the link target. - * - * Available options are: - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * Note: This property must only be used when the `href` property is set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTarget( - /** - * New value for property `target` - */ - sTarget?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the BreadcrumbsItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $BreadcrumbsItemSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the item. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the link href. - * - * **Note:** Standard hyperlink behavior is supported. - */ - href?: string | PropertyBindingInfo; - - /** - * Defines the link target. - * - * Available options are: - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * Note: This property must only be used when the `href` property is set. - */ - target?: string | PropertyBindingInfo; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/BusyIndicator" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { BusyIndicatorSize } from "sap/ui/webc/main/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.BusyIndicator` signals that some operation is going on and that the user must wait. - * It does not block the current UI screen so other operations could be triggered in parallel. It displays - * 3 dots and each dot expands and shrinks at a different rate, resulting in a cascading flow of animation. - * - * Usage: For the `sap.ui.webc.main.BusyIndicator` you can define the size, the text and whether it is shown - * or hidden. In order to hide it, use the "active" property. - * - * In order to show busy state over an HTML element, simply nest the HTML element in a `sap.ui.webc.main.BusyIndicator` - * instance. - * **Note:** Since `sap.ui.webc.main.BusyIndicator` has `display: inline-block;` by default and no width - * of its own, whenever you need to wrap a block-level element, you should set `display: block` to the busy - * indicator as well. - * - * When to use:: - * - The user needs to be able to cancel the operation. - * - Only part of the application or a particular component is affected. - * - * When not to use:: - * - The operation takes less than one second. - * - You need to block the screen and prevent the user from starting another activity. - * - Do not show multiple busy indicators at once. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class BusyIndicator extends WebComponent { - /** - * Constructor for a new `BusyIndicator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $BusyIndicatorSettings - ); - /** - * Constructor for a new `BusyIndicator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $BusyIndicatorSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.BusyIndicator with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.BusyIndicator. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Gets current value of property {@link #getActive active}. - * - * Defines if the busy indicator is visible on the screen. By default it is not. - * - * Default value is `false`. - * - * - * @returns Value of property `active` - */ - getActive(): boolean; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Determines the content over which the component will appear. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getDelay delay}. - * - * Defines the delay in milliseconds, after which the busy indicator will be visible on the screen. - * - * Default value is `1000`. - * - * - * @returns Value of property `delay` - */ - getDelay(): int; - /** - * Gets current value of property {@link #getDisplay display}. - * - * Defines whether the control will be rendered as a block or inline HTML element - * - * Default value is `"inline-block"`. - * - * - * @returns Value of property `display` - */ - getDisplay(): string; - /** - * Gets current value of property {@link #getSize size}. - * - * Defines the size of the component. - * - * Default value is `Medium`. - * - * - * @returns Value of property `size` - */ - getSize(): BusyIndicatorSize; - /** - * Gets current value of property {@link #getText text}. - * - * Defines text to be displayed below the component. It can be used to inform the user of the current operation. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getActive active}. - * - * Defines if the busy indicator is visible on the screen. By default it is not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setActive( - /** - * New value for property `active` - */ - bActive?: boolean - ): this; - /** - * Sets a new value for property {@link #getDelay delay}. - * - * Defines the delay in milliseconds, after which the busy indicator will be visible on the screen. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDelay( - /** - * New value for property `delay` - */ - iDelay?: int - ): this; - /** - * Sets a new value for property {@link #getDisplay display}. - * - * Defines whether the control will be rendered as a block or inline HTML element - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `"inline-block"`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDisplay( - /** - * New value for property `display` - */ - sDisplay?: string - ): this; - /** - * Sets a new value for property {@link #getSize size}. - * - * Defines the size of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Medium`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSize( - /** - * New value for property `size` - */ - sSize?: BusyIndicatorSize | keyof typeof BusyIndicatorSize - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines text to be displayed below the component. It can be used to inform the user of the current operation. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the BusyIndicator constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $BusyIndicatorSettings extends $WebComponentSettings { - /** - * Defines if the busy indicator is visible on the screen. By default it is not. - */ - active?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the delay in milliseconds, after which the busy indicator will be visible on the screen. - */ - delay?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the control will be rendered as a block or inline HTML element - */ - display?: string | PropertyBindingInfo; - - /** - * Defines the size of the component. - */ - size?: - | (BusyIndicatorSize | keyof typeof BusyIndicatorSize) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines text to be displayed below the component. It can be used to inform the user of the current operation. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the content over which the component will appear. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/Button" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IButton, ButtonDesign, ButtonType } from "sap/ui/webc/main/library"; - - import { - IFormContent, - ID, - TextDirection, - CSSSize, - } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Button` component represents a simple push button. It enables users to trigger - * actions by clicking or tapping the `sap.ui.webc.main.Button`, or by pressing certain keyboard keys, such - * as Enter. - * - * Usage: - * - * For the `sap.ui.webc.main.Button` UI, you can define text, icon, or both. You can also specify whether - * the text or the icon is displayed first. - * - * You can choose from a set of predefined types that offer different styling to correspond to the triggered - * action. - * - * You can set the `sap.ui.webc.main.Button` as enabled or disabled. An enabled `sap.ui.webc.main.Button` - * can be pressed by clicking or tapping it. The button changes its style to provide visual feedback to - * the user that it is pressed or hovered over with the mouse cursor. A disabled `sap.ui.webc.main.Button` - * appears inactive and cannot be pressed. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Button` exposes the following CSS Shadow Parts: - * - button - Used to style the native button element - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Button - extends WebComponent - implements IButton, IFormContent - { - __implements__sap_ui_webc_main_IButton: boolean; - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `Button`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ButtonSettings - ); - /** - * Constructor for a new `Button`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ButtonSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Button with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Button. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Button`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Button` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Button` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Button`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Button` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Button` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.Button`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component design. - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): ButtonDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIconEnd iconEnd}. - * - * Defines whether the icon should be displayed after the component text. - * - * Default value is `false`. - * - * - * @returns Value of property `iconEnd` - */ - getIconEnd(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getTextDirection textDirection}. - * - * Specifies the element's text directionality with enumerated options. By default, the control inherits - * text direction from the DOM. - * - * Default value is `Inherit`. - * - * - * @returns Value of property `textDirection` - */ - getTextDirection(): TextDirection; - /** - * Gets current value of property {@link #getType type}. - * - * Defines whether the button has special form-related functionality. - * - * Default value is `Button`. - * - * - * @returns Value of property `type` - */ - getType(): ButtonType; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: ButtonDesign | keyof typeof ButtonDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getIconEnd iconEnd}. - * - * Defines whether the icon should be displayed after the component text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIconEnd( - /** - * New value for property `iconEnd` - */ - bIconEnd?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getTextDirection textDirection}. - * - * Specifies the element's text directionality with enumerated options. By default, the control inherits - * text direction from the DOM. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Inherit`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTextDirection( - /** - * New value for property `textDirection` - */ - sTextDirection?: TextDirection | keyof typeof TextDirection - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines whether the button has special form-related functionality. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Button`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ButtonType | keyof typeof ButtonType - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Button constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ButtonSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the component design. - */ - design?: - | (ButtonDesign | keyof typeof ButtonDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the icon should be displayed after the component text. - */ - iconEnd?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Specifies the element's text directionality with enumerated options. By default, the control inherits - * text direction from the DOM. - */ - textDirection?: - | (TextDirection | keyof typeof TextDirection) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the button has special form-related functionality. - */ - type?: - | (ButtonType | keyof typeof ButtonType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the Button#click event. - */ - export interface Button$ClickEventParameters {} - - /** - * Event object of the Button#click event. - */ - export type Button$ClickEvent = Event; -} - -declare module "sap/ui/webc/main/Calendar" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - ICalendarDate, - CalendarSelectionMode, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import CalendarType from "sap/ui/core/CalendarType"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Calendar` component allows users to select one or more dates. - * - * Currently selected dates are represented with instances of `sap.ui.webc.main.CalendarDate` as children - * of the `sap.ui.webc.main.Calendar`. The value property of each `sap.ui.webc.main.CalendarDate` must be - * a date string, correctly formatted according to the `sap.ui.webc.main.Calendar`'s `formatPattern` property. - * Whenever the user changes the date selection, `sap.ui.webc.main.Calendar` will automatically create/remove - * instances of `sap.ui.webc.main.CalendarDate` in itself, unless you prevent this behavior by calling `preventDefault()` - * for the `selected-dates-change` event. This is useful if you want to control the selected dates externally. - * - * - * - * - * Usage: - * - * The user can navigate to a particular date by: - * - * - * - * - Pressing over a month inside the months view - * - Pressing over an year inside the years view - * The user can confirm a date selection by pressing over a date inside the days view. - * - * - * - * Keyboard Handling: The `sap.ui.webc.main.Calendar` provides advanced keyboard handling. When a picker - * is showed and focused the user can use the following keyboard shortcuts in order to perform a navigation: - * - * - Day picker: - * - * - * - * - [F4] - Shows month picker - * - [SHIFT] + [F4] - Shows year picker - * - [PAGEUP] - Navigate to the previous month - * - [PAGEDOWN] - Navigate to the next month - * - [SHIFT] + [PAGEUP] - Navigate to the previous year - * - [SHIFT] + [PAGEDOWN] - Navigate to the next year - * - [CTRL] + [SHIFT] + [PAGEUP] - Navigate ten years backwards - * - [CTRL] + [SHIFT] + [PAGEDOWN] - Navigate ten years forwards - * - [HOME] - Navigate to the first day of the week - * - [END] - Navigate to the last day of the week - * - [CTRL] + [HOME] - Navigate to the first day of the month - * - [CTRL] + [END] - Navigate to the last day of the month - * - Month picker: - * - * - * - * - [PAGEUP] - Navigate to the previous year - * - [PAGEDOWN] - Navigate to the next year - * - [HOME] - Navigate to the first month of the current row - * - [END] - Navigate to the last month of the current row - * - [CTRL] + [HOME] - Navigate to the first month of the current year - * - [CTRL] + [END] - Navigate to the last month of the year - * - Year picker: - * - * - * - * - [PAGEUP] - Navigate to the previous year range - * - [PAGEDOWN] - Navigate the next year range - * - [HOME] - Navigate to the first year of the current row - * - [END] - Navigate to the last year of the current row - * - [CTRL] + [HOME] - Navigate to the first year of the current year range - * - [CTRL] + [END] - Navigate to the last year of the current year range - * - * - * Calendar types: The component supports several calendar types - Gregorian, Buddhist, Islamic, Japanese - * and Persian. By default the Gregorian Calendar is used. In order to use the Buddhist, Islamic, Japanese - * or Persian calendar, you need to set the `primaryCalendarType` property and import one or more of the - * following modules: - * - * - * - * Or, you can use the global configuration and set the `calendarType` key: - * ` - * ` - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Calendar extends WebComponent { - /** - * Constructor for a new `Calendar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $CalendarSettings - ); - /** - * Constructor for a new `Calendar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $CalendarSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Calendar with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Calendar. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some date to the aggregation {@link #getDates dates}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addDate( - /** - * The date to add; if empty, nothing is inserted - */ - oDate: ICalendarDate - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectedDatesChange selectedDatesChange} event - * of this `sap.ui.webc.main.Calendar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Calendar` itself. - * - * Fired when the selected dates change. **Note:** If you call `preventDefault()` for this event, the component - * will not create instances of `sap.ui.webc.main.CalendarDate` for the newly selected dates. In that case - * you should do this manually. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectedDatesChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Calendar$SelectedDatesChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Calendar` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectedDatesChange selectedDatesChange} event - * of this `sap.ui.webc.main.Calendar`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Calendar` itself. - * - * Fired when the selected dates change. **Note:** If you call `preventDefault()` for this event, the component - * will not create instances of `sap.ui.webc.main.CalendarDate` for the newly selected dates. In that case - * you should do this manually. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectedDatesChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Calendar$SelectedDatesChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Calendar` itself - */ - oListener?: object - ): this; - /** - * Destroys all the dates in the aggregation {@link #getDates dates}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyDates(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectedDatesChange selectedDatesChange} event - * of this `sap.ui.webc.main.Calendar`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectedDatesChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Calendar$SelectedDatesChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:selectedDatesChange selectedDatesChange} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireSelectedDatesChange( - /** - * Parameters to pass along with the event - */ - mParameters?: Calendar$SelectedDatesChangeEventParameters - ): boolean; - /** - * Gets content of aggregation {@link #getDates dates}. - * - * Defines the selected date or dates (depending on the `selectionMode` property) for this calendar as instances - * of `sap.ui.webc.main.CalendarDate`. - */ - getDates(): ICalendarDate[]; - /** - * Gets current value of property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * Default value is `empty string`. - * - * - * @returns Value of property `formatPattern` - */ - getFormatPattern(): string; - /** - * Gets current value of property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * Default value is `false`. - * - * - * @returns Value of property `hideWeekNumbers` - */ - getHideWeekNumbers(): boolean; - /** - * Gets current value of property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `maxDate` - */ - getMaxDate(): string; - /** - * Gets current value of property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `minDate` - */ - getMinDate(): string; - /** - * Gets current value of property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * - * @returns Value of property `primaryCalendarType` - */ - getPrimaryCalendarType(): CalendarType; - /** - * Gets current value of property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * Default value is `undefined`. - * - * - * @returns Value of property `secondaryCalendarType` - */ - getSecondaryCalendarType(): CalendarType; - /** - * Gets current value of property {@link #getSelectionMode selectionMode}. - * - * Defines the type of selection used in the calendar component. Accepted property values are: - * - * - * - * - `CalendarSelectionMode.Single` - enables a single date selection.(default value) - * - `CalendarSelectionMode.Range` - enables selection of a date range. - * - `CalendarSelectionMode.Multiple` - enables selection of multiple dates. - * - * Default value is `Single`. - * - * - * @returns Value of property `selectionMode` - */ - getSelectionMode(): CalendarSelectionMode; - /** - * Checks for the provided `sap.ui.webc.main.ICalendarDate` in the aggregation {@link #getDates dates}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfDate( - /** - * The date whose index is looked for - */ - oDate: ICalendarDate - ): int; - /** - * Inserts a date into the aggregation {@link #getDates dates}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertDate( - /** - * The date to insert; if empty, nothing is inserted - */ - oDate: ICalendarDate, - /** - * The `0`-based index the date should be inserted at; for a negative value of `iIndex`, the date is inserted - * at position 0; for a value greater than the current size of the aggregation, the date is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getDates dates}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllDates(): ICalendarDate[]; - /** - * Removes a date from the aggregation {@link #getDates dates}. - * - * - * @returns The removed date or `null` - */ - removeDate( - /** - * The date to remove or its index or id - */ - vDate: int | string | ICalendarDate - ): ICalendarDate | null; - /** - * Sets a new value for property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFormatPattern( - /** - * New value for property `formatPattern` - */ - sFormatPattern?: string - ): this; - /** - * Sets a new value for property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideWeekNumbers( - /** - * New value for property `hideWeekNumbers` - */ - bHideWeekNumbers?: boolean - ): this; - /** - * Sets a new value for property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMaxDate( - /** - * New value for property `maxDate` - */ - sMaxDate?: string - ): this; - /** - * Sets a new value for property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMinDate( - /** - * New value for property `minDate` - */ - sMinDate?: string - ): this; - /** - * Sets a new value for property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPrimaryCalendarType( - /** - * New value for property `primaryCalendarType` - */ - sPrimaryCalendarType: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSecondaryCalendarType( - /** - * New value for property `secondaryCalendarType` - */ - sSecondaryCalendarType?: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getSelectionMode selectionMode}. - * - * Defines the type of selection used in the calendar component. Accepted property values are: - * - * - * - * - `CalendarSelectionMode.Single` - enables a single date selection.(default value) - * - `CalendarSelectionMode.Range` - enables selection of a date range. - * - `CalendarSelectionMode.Multiple` - enables selection of multiple dates. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Single`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelectionMode( - /** - * New value for property `selectionMode` - */ - sSelectionMode?: - | CalendarSelectionMode - | keyof typeof CalendarSelectionMode - ): this; - } - /** - * Describes the settings that can be provided to the Calendar constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $CalendarSettings extends $WebComponentSettings { - /** - * Determines the format, displayed in the input field. - */ - formatPattern?: string | PropertyBindingInfo; - - /** - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - */ - hideWeekNumbers?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - maxDate?: string | PropertyBindingInfo; - - /** - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - minDate?: string | PropertyBindingInfo; - - /** - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - */ - primaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - */ - secondaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the type of selection used in the calendar component. Accepted property values are: - * - * - * - * - `CalendarSelectionMode.Single` - enables a single date selection.(default value) - * - `CalendarSelectionMode.Range` - enables selection of a date range. - * - `CalendarSelectionMode.Multiple` - enables selection of multiple dates. - */ - selectionMode?: - | (CalendarSelectionMode | keyof typeof CalendarSelectionMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the selected date or dates (depending on the `selectionMode` property) for this calendar as instances - * of `sap.ui.webc.main.CalendarDate`. - */ - dates?: - | ICalendarDate[] - | ICalendarDate - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the selected dates change. **Note:** If you call `preventDefault()` for this event, the component - * will not create instances of `sap.ui.webc.main.CalendarDate` for the newly selected dates. In that case - * you should do this manually. - */ - selectedDatesChange?: (oEvent: Calendar$SelectedDatesChangeEvent) => void; - } - - /** - * Parameters of the Calendar#selectedDatesChange event. - */ - export interface Calendar$SelectedDatesChangeEventParameters { - /** - * The selected dates - */ - values?: any[]; - - /** - * The selected dates as UTC timestamps - */ - dates?: any[]; - } - - /** - * Event object of the Calendar#selectedDatesChange event. - */ - export type Calendar$SelectedDatesChangeEvent = Event< - Calendar$SelectedDatesChangeEventParameters, - Calendar - >; -} - -declare module "sap/ui/webc/main/CalendarDate" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ICalendarDate } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.CalendarDate` component defines a calendar date to be used inside `sap.ui.webc.main.Calendar` - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class CalendarDate - extends WebComponent - implements ICalendarDate - { - __implements__sap_ui_webc_main_ICalendarDate: boolean; - /** - * Constructor for a new `CalendarDate`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $CalendarDateSettings - ); - /** - * Constructor for a new `CalendarDate`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $CalendarDateSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.CalendarDate with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.CalendarDate. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getValue value}. - * - * The date formatted according to the `formatPattern` property of the `sap.ui.webc.main.Calendar` that - * hosts the component. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Sets a new value for property {@link #getValue value}. - * - * The date formatted according to the `formatPattern` property of the `sap.ui.webc.main.Calendar` that - * hosts the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue: string - ): this; - } - /** - * Describes the settings that can be provided to the CalendarDate constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $CalendarDateSettings extends $WebComponentSettings { - /** - * The date formatted according to the `formatPattern` property of the `sap.ui.webc.main.Calendar` that - * hosts the component. - */ - value?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/Card" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { ICardHeader } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Card` is a component that represents information in the form of a tile with separate - * header and content areas. The content area of a `sap.ui.webc.main.Card` can be arbitrary HTML content. - * The header can be used through slot `header`. For which there is a `sap.ui.webc.main.CardHeader` component - * to achieve the card look and feel. - * - * Note: We recommend the usage of `sap.ui.webc.main.CardHeader` for the header slot, so advantage can be - * taken for keyboard handling, styling and accessibility. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Card extends WebComponent { - /** - * Constructor for a new `Card`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $CardSettings - ); - /** - * Constructor for a new `Card`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $CardSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Card with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Card. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: ICardHeader - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component, which is used as the name of the card region and should - * be unique per card. **Note:** `accessibleName` should be always set, unless `ariaLabelledBy` is set. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the component. - */ - getContent(): Control[]; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the header of the component. - * - * **Note:** Use `sap.ui.webc.main.CardHeader` for the intended design. - */ - getHeader(): ICardHeader[]; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.main.ICardHeader` in the aggregation {@link #getHeader header}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: ICardHeader - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: ICardHeader, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): ICardHeader[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | ICardHeader - ): ICardHeader | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component, which is used as the name of the card region and should - * be unique per card. **Note:** `accessibleName` should be always set, unless `ariaLabelledBy` is set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Card constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $CardSettings extends $WebComponentSettings { - /** - * Defines the accessible name of the component, which is used as the name of the card region and should - * be unique per card. **Note:** `accessibleName` should be always set, unless `ariaLabelledBy` is set. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the component. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the header of the component. - * - * **Note:** Use `sap.ui.webc.main.CardHeader` for the intended design. - */ - header?: - | ICardHeader[] - | ICardHeader - | AggregationBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - } -} - -declare module "sap/ui/webc/main/CardHeader" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ICardHeader } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.CardHeader` is a component, meant to be used as a header of the `sap.ui.webc.main.Card` - * component. It displays valuable information, that can be defined with several properties, such as: `titleText`, - * `subtitleText`, `status` and two slots: `avatar` and `action`. - * - * Keyboard handling: In case you enable `interactive` property, you can press the `sap.ui.webc.main.CardHeader` - * by Space and Enter keys. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.CardHeader` exposes the following CSS Shadow Parts: - * - root - Used to style the root DOM element of the CardHeader - * - title - Used to style the title of the CardHeader - * - subtitle - Used to style the subtitle of the CardHeader - * - status - Used to style the status of the CardHeader - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class CardHeader extends WebComponent implements ICardHeader { - __implements__sap_ui_webc_main_ICardHeader: boolean; - /** - * Constructor for a new `CardHeader`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $CardHeaderSettings - ); - /** - * Constructor for a new `CardHeader`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $CardHeaderSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.CardHeader with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.CardHeader. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some action to the aggregation {@link #getAction action}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAction( - /** - * The action to add; if empty, nothing is inserted - */ - oAction: Control - ): this; - /** - * Adds some avatar to the aggregation {@link #getAvatar avatar}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAvatar( - /** - * The avatar to add; if empty, nothing is inserted - */ - oAvatar: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.CardHeader`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.CardHeader` itself. - * - * Fired when the component is activated by mouse/tap or by using the Enter or Space key. - * - * **Note:** The event would be fired only if the `interactive` property is set to true. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.CardHeader` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.CardHeader`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.CardHeader` itself. - * - * Fired when the component is activated by mouse/tap or by using the Enter or Space key. - * - * **Note:** The event would be fired only if the `interactive` property is set to true. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.CardHeader` itself - */ - oListener?: object - ): this; - /** - * Destroys all the action in the aggregation {@link #getAction action}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyAction(): this; - /** - * Destroys all the avatar in the aggregation {@link #getAvatar avatar}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyAvatar(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.CardHeader`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets content of aggregation {@link #getAction action}. - * - * Defines an action, displayed in the right most part of the header. - */ - getAction(): Control[]; - /** - * Gets content of aggregation {@link #getAvatar avatar}. - * - * Defines an avatar image, displayed in the left most part of the header. - */ - getAvatar(): Control[]; - /** - * Gets current value of property {@link #getInteractive interactive}. - * - * Defines if the component would be interactive, e.g gets hover effect, gets focus outline and `click` - * event is fired, when pressed. - * - * Default value is `false`. - * - * - * @returns Value of property `interactive` - */ - getInteractive(): boolean; - /** - * Gets current value of property {@link #getStatus status}. - * - * Defines the status text. - * - * Default value is `empty string`. - * - * - * @returns Value of property `status` - */ - getStatus(): string; - /** - * Gets current value of property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle text. - * - * Default value is `empty string`. - * - * - * @returns Value of property `subtitleText` - */ - getSubtitleText(): string; - /** - * Gets current value of property {@link #getTitleText titleText}. - * - * Defines the title text. - * - * Default value is `empty string`. - * - * - * @returns Value of property `titleText` - */ - getTitleText(): string; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getAction action}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfAction( - /** - * The action whose index is looked for - */ - oAction: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getAvatar avatar}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfAvatar( - /** - * The avatar whose index is looked for - */ - oAvatar: Control - ): int; - /** - * Inserts a action into the aggregation {@link #getAction action}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertAction( - /** - * The action to insert; if empty, nothing is inserted - */ - oAction: Control, - /** - * The `0`-based index the action should be inserted at; for a negative value of `iIndex`, the action is - * inserted at position 0; for a value greater than the current size of the aggregation, the action is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a avatar into the aggregation {@link #getAvatar avatar}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertAvatar( - /** - * The avatar to insert; if empty, nothing is inserted - */ - oAvatar: Control, - /** - * The `0`-based index the avatar should be inserted at; for a negative value of `iIndex`, the avatar is - * inserted at position 0; for a value greater than the current size of the aggregation, the avatar is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Removes a action from the aggregation {@link #getAction action}. - * - * - * @returns The removed action or `null` - */ - removeAction( - /** - * The action to remove or its index or id - */ - vAction: int | string | Control - ): Control | null; - /** - * Removes all the controls from the aggregation {@link #getAction action}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAction(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getAvatar avatar}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAvatar(): Control[]; - /** - * Removes a avatar from the aggregation {@link #getAvatar avatar}. - * - * - * @returns The removed avatar or `null` - */ - removeAvatar( - /** - * The avatar to remove or its index or id - */ - vAvatar: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getInteractive interactive}. - * - * Defines if the component would be interactive, e.g gets hover effect, gets focus outline and `click` - * event is fired, when pressed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInteractive( - /** - * New value for property `interactive` - */ - bInteractive?: boolean - ): this; - /** - * Sets a new value for property {@link #getStatus status}. - * - * Defines the status text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStatus( - /** - * New value for property `status` - */ - sStatus?: string - ): this; - /** - * Sets a new value for property {@link #getSubtitleText subtitleText}. - * - * Defines the subtitle text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSubtitleText( - /** - * New value for property `subtitleText` - */ - sSubtitleText?: string - ): this; - /** - * Sets a new value for property {@link #getTitleText titleText}. - * - * Defines the title text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTitleText( - /** - * New value for property `titleText` - */ - sTitleText?: string - ): this; - } - /** - * Describes the settings that can be provided to the CardHeader constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $CardHeaderSettings extends $WebComponentSettings { - /** - * Defines if the component would be interactive, e.g gets hover effect, gets focus outline and `click` - * event is fired, when pressed. - */ - interactive?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the status text. - */ - status?: string | PropertyBindingInfo; - - /** - * Defines the subtitle text. - */ - subtitleText?: string | PropertyBindingInfo; - - /** - * Defines the title text. - */ - titleText?: string | PropertyBindingInfo; - - /** - * Defines an action, displayed in the right most part of the header. - */ - action?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines an avatar image, displayed in the left most part of the header. - */ - avatar?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the component is activated by mouse/tap or by using the Enter or Space key. - * - * **Note:** The event would be fired only if the `interactive` property is set to true. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the CardHeader#click event. - */ - export interface CardHeader$ClickEventParameters {} - - /** - * Event object of the CardHeader#click event. - */ - export type CardHeader$ClickEvent = Event< - CardHeader$ClickEventParameters, - CardHeader - >; -} - -declare module "sap/ui/webc/main/Carousel" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Control from "sap/ui/core/Control"; - - import { - CarouselArrowsPlacement, - BackgroundDesign, - BorderDesign, - CarouselPageIndicatorStyle, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The Carousel allows the user to browse through a set of items. The component is mostly used - * for showing a gallery of images, but can hold any other HTML element. - * There are several ways to perform navigation: - * - on desktop - the user can navigate using the navigation arrows or with keyboard shorcuts. - * - on mobile - the user can use swipe gestures. - * - * Usage: - * - * When to use:: - * - * - * - The items you want to display are very different from each other. - * - You want to display the items one after the other. - * - * When not to use:: - * - * - * - The items you want to display need to be visible at the same time. - * - The items you want to display are uniform and very similar. - * - * Keyboard Handling: - * - * Basic Navigation: When the `sap.ui.webc.main.Carousel` is focused the user can navigate between the items - * with the following keyboard shortcuts: - * - * - * - * - [UP/DOWN] - Navigates to previous and next item - * - [LEFT/RIGHT] - Navigates to previous and next item - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Carousel` exposes the following CSS Shadow Parts: - * - content - Used to style the content of the component - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Carousel extends WebComponent { - /** - * Constructor for a new `Carousel`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $CarouselSettings - ); - /** - * Constructor for a new `Carousel`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $CarouselSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Carousel with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Carousel. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:navigate navigate} event of this `sap.ui.webc.main.Carousel`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Carousel` itself. - * - * Fired whenever the page changes due to user interaction, when the user clicks on the navigation arrows - * or while resizing, based on the `items-per-page-l`, `items-per-page-m` and `items-per-page-s` properties. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachNavigate( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Carousel$NavigateEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Carousel` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:navigate navigate} event of this `sap.ui.webc.main.Carousel`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Carousel` itself. - * - * Fired whenever the page changes due to user interaction, when the user clicks on the navigation arrows - * or while resizing, based on the `items-per-page-l`, `items-per-page-m` and `items-per-page-s` properties. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachNavigate( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Carousel$NavigateEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Carousel` itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:navigate navigate} event of this `sap.ui.webc.main.Carousel`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachNavigate( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Carousel$NavigateEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:navigate navigate} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireNavigate( - /** - * Parameters to pass along with the event - */ - mParameters?: Carousel$NavigateEventParameters - ): this; - /** - * Gets current value of property {@link #getArrowsPlacement arrowsPlacement}. - * - * Defines the position of arrows. - * - * Available options are: - * - `Content` - the arrows are placed on the sides of the current page. - * - `Navigation` - the arrows are placed on the sides of the page indicator. - * - * Default value is `Content`. - * - * - * @returns Value of property `arrowsPlacement` - */ - getArrowsPlacement(): CarouselArrowsPlacement; - /** - * Gets current value of property {@link #getBackgroundDesign backgroundDesign}. - * - * Defines the carousel's background design. - * - * Default value is `Translucent`. - * - * - * @returns Value of property `backgroundDesign` - */ - getBackgroundDesign(): BackgroundDesign; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the component. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getCyclic cyclic}. - * - * Defines whether the carousel should loop, i.e show the first page after the last page is reached and - * vice versa. - * - * Default value is `false`. - * - * - * @returns Value of property `cyclic` - */ - getCyclic(): boolean; - /** - * Gets current value of property {@link #getHideNavigationArrows hideNavigationArrows}. - * - * Defines the visibility of the navigation arrows. If set to true the navigation arrows will be hidden. - * - * - * **Note:** The navigation arrows are never displayed on touch devices. In this case, the user can swipe - * to navigate through the items. - * - * Default value is `false`. - * - * - * @returns Value of property `hideNavigationArrows` - */ - getHideNavigationArrows(): boolean; - /** - * Gets current value of property {@link #getHidePageIndicator hidePageIndicator}. - * - * Defines the visibility of the page indicator. If set to true the page indicator will be hidden. - * - * Default value is `false`. - * - * - * @returns Value of property `hidePageIndicator` - */ - getHidePageIndicator(): boolean; - /** - * Gets current value of property {@link #getItemsPerPageL itemsPerPageL}. - * - * Defines the number of items per page on large size (more than 1024px). One item per page shown by default. - * - * Default value is `1`. - * - * - * @returns Value of property `itemsPerPageL` - */ - getItemsPerPageL(): int; - /** - * Gets current value of property {@link #getItemsPerPageM itemsPerPageM}. - * - * Defines the number of items per page on medium size (from 640px to 1024px). One item per page shown by - * default. - * - * Default value is `1`. - * - * - * @returns Value of property `itemsPerPageM` - */ - getItemsPerPageM(): int; - /** - * Gets current value of property {@link #getItemsPerPageS itemsPerPageS}. - * - * Defines the number of items per page on small size (up to 640px). One item per page shown by default. - * - * Default value is `1`. - * - * - * @returns Value of property `itemsPerPageS` - */ - getItemsPerPageS(): int; - /** - * Gets current value of property {@link #getPageIndicatorBackgroundDesign pageIndicatorBackgroundDesign}. - * - * Defines the page indicator background design. - * - * Default value is `Solid`. - * - * - * @returns Value of property `pageIndicatorBackgroundDesign` - */ - getPageIndicatorBackgroundDesign(): BackgroundDesign; - /** - * Gets current value of property {@link #getPageIndicatorBorderDesign pageIndicatorBorderDesign}. - * - * Defines the page indicator border design. - * - * Default value is `Solid`. - * - * - * @returns Value of property `pageIndicatorBorderDesign` - */ - getPageIndicatorBorderDesign(): BorderDesign; - /** - * Gets current value of property {@link #getPageIndicatorStyle pageIndicatorStyle}. - * - * Defines the style of the page indicator. Available options are: - * - `Default` - The page indicator will be visualized as dots if there are fewer than 9 pages. If there - * are more pages, the page indicator will switch to displaying the current page and the total number of - * pages. (e.g. X of Y) - * - `Numeric` - The page indicator will display the current page and the total number of pages. (e.g. - * X of Y) - * - * Default value is `Default`. - * - * - * @returns Value of property `pageIndicatorStyle` - */ - getPageIndicatorStyle(): CarouselPageIndicatorStyle; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Changes the currently displayed page. - */ - navigateTo( - /** - * The index of the target page - */ - itemIndex: int - ): void; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getArrowsPlacement arrowsPlacement}. - * - * Defines the position of arrows. - * - * Available options are: - * - `Content` - the arrows are placed on the sides of the current page. - * - `Navigation` - the arrows are placed on the sides of the page indicator. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Content`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setArrowsPlacement( - /** - * New value for property `arrowsPlacement` - */ - sArrowsPlacement?: - | CarouselArrowsPlacement - | keyof typeof CarouselArrowsPlacement - ): this; - /** - * Sets a new value for property {@link #getBackgroundDesign backgroundDesign}. - * - * Defines the carousel's background design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Translucent`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBackgroundDesign( - /** - * New value for property `backgroundDesign` - */ - sBackgroundDesign?: BackgroundDesign | keyof typeof BackgroundDesign - ): this; - /** - * Sets a new value for property {@link #getCyclic cyclic}. - * - * Defines whether the carousel should loop, i.e show the first page after the last page is reached and - * vice versa. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setCyclic( - /** - * New value for property `cyclic` - */ - bCyclic?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideNavigationArrows hideNavigationArrows}. - * - * Defines the visibility of the navigation arrows. If set to true the navigation arrows will be hidden. - * - * - * **Note:** The navigation arrows are never displayed on touch devices. In this case, the user can swipe - * to navigate through the items. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideNavigationArrows( - /** - * New value for property `hideNavigationArrows` - */ - bHideNavigationArrows?: boolean - ): this; - /** - * Sets a new value for property {@link #getHidePageIndicator hidePageIndicator}. - * - * Defines the visibility of the page indicator. If set to true the page indicator will be hidden. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHidePageIndicator( - /** - * New value for property `hidePageIndicator` - */ - bHidePageIndicator?: boolean - ): this; - /** - * Sets a new value for property {@link #getItemsPerPageL itemsPerPageL}. - * - * Defines the number of items per page on large size (more than 1024px). One item per page shown by default. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setItemsPerPageL( - /** - * New value for property `itemsPerPageL` - */ - iItemsPerPageL?: int - ): this; - /** - * Sets a new value for property {@link #getItemsPerPageM itemsPerPageM}. - * - * Defines the number of items per page on medium size (from 640px to 1024px). One item per page shown by - * default. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setItemsPerPageM( - /** - * New value for property `itemsPerPageM` - */ - iItemsPerPageM?: int - ): this; - /** - * Sets a new value for property {@link #getItemsPerPageS itemsPerPageS}. - * - * Defines the number of items per page on small size (up to 640px). One item per page shown by default. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setItemsPerPageS( - /** - * New value for property `itemsPerPageS` - */ - iItemsPerPageS?: int - ): this; - /** - * Sets a new value for property {@link #getPageIndicatorBackgroundDesign pageIndicatorBackgroundDesign}. - * - * Defines the page indicator background design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Solid`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPageIndicatorBackgroundDesign( - /** - * New value for property `pageIndicatorBackgroundDesign` - */ - sPageIndicatorBackgroundDesign?: - | BackgroundDesign - | keyof typeof BackgroundDesign - ): this; - /** - * Sets a new value for property {@link #getPageIndicatorBorderDesign pageIndicatorBorderDesign}. - * - * Defines the page indicator border design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Solid`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPageIndicatorBorderDesign( - /** - * New value for property `pageIndicatorBorderDesign` - */ - sPageIndicatorBorderDesign?: BorderDesign | keyof typeof BorderDesign - ): this; - /** - * Sets a new value for property {@link #getPageIndicatorStyle pageIndicatorStyle}. - * - * Defines the style of the page indicator. Available options are: - * - `Default` - The page indicator will be visualized as dots if there are fewer than 9 pages. If there - * are more pages, the page indicator will switch to displaying the current page and the total number of - * pages. (e.g. X of Y) - * - `Numeric` - The page indicator will display the current page and the total number of pages. (e.g. - * X of Y) - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPageIndicatorStyle( - /** - * New value for property `pageIndicatorStyle` - */ - sPageIndicatorStyle?: - | CarouselPageIndicatorStyle - | keyof typeof CarouselPageIndicatorStyle - ): this; - } - /** - * Describes the settings that can be provided to the Carousel constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $CarouselSettings extends $WebComponentSettings { - /** - * Defines the position of arrows. - * - * Available options are: - * - `Content` - the arrows are placed on the sides of the current page. - * - `Navigation` - the arrows are placed on the sides of the page indicator. - */ - arrowsPlacement?: - | (CarouselArrowsPlacement | keyof typeof CarouselArrowsPlacement) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the carousel's background design. - */ - backgroundDesign?: - | (BackgroundDesign | keyof typeof BackgroundDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the carousel should loop, i.e show the first page after the last page is reached and - * vice versa. - */ - cyclic?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visibility of the navigation arrows. If set to true the navigation arrows will be hidden. - * - * - * **Note:** The navigation arrows are never displayed on touch devices. In this case, the user can swipe - * to navigate through the items. - */ - hideNavigationArrows?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visibility of the page indicator. If set to true the page indicator will be hidden. - */ - hidePageIndicator?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the number of items per page on large size (more than 1024px). One item per page shown by default. - */ - itemsPerPageL?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the number of items per page on medium size (from 640px to 1024px). One item per page shown by - * default. - */ - itemsPerPageM?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the number of items per page on small size (up to 640px). One item per page shown by default. - */ - itemsPerPageS?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the page indicator background design. - */ - pageIndicatorBackgroundDesign?: - | (BackgroundDesign | keyof typeof BackgroundDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the page indicator border design. - */ - pageIndicatorBorderDesign?: - | (BorderDesign | keyof typeof BorderDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the style of the page indicator. Available options are: - * - `Default` - The page indicator will be visualized as dots if there are fewer than 9 pages. If there - * are more pages, the page indicator will switch to displaying the current page and the total number of - * pages. (e.g. X of Y) - * - `Numeric` - The page indicator will display the current page and the total number of pages. (e.g. - * X of Y) - */ - pageIndicatorStyle?: - | (CarouselPageIndicatorStyle | keyof typeof CarouselPageIndicatorStyle) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the content of the component. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Fired whenever the page changes due to user interaction, when the user clicks on the navigation arrows - * or while resizing, based on the `items-per-page-l`, `items-per-page-m` and `items-per-page-s` properties. - */ - navigate?: (oEvent: Carousel$NavigateEvent) => void; - } - - /** - * Parameters of the Carousel#navigate event. - */ - export interface Carousel$NavigateEventParameters { - /** - * the current selected index - */ - selectedIndex?: int; - } - - /** - * Event object of the Carousel#navigate event. - */ - export type Carousel$NavigateEvent = Event< - Carousel$NavigateEventParameters, - Carousel - >; -} - -declare module "sap/ui/webc/main/CheckBox" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { WrappingType } from "sap/ui/webc/main/library"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * Allows the user to set a binary value, such as true/false or yes/no for an item. - * - * The `sap.ui.webc.main.CheckBox` component consists of a box and a label that describes its purpose. - * If it's checked, an indicator is displayed inside the box. To check/uncheck the `sap.ui.webc.main.CheckBox`, - * the user has to click or tap the square box or its label. - * - * The `sap.ui.webc.main.CheckBox` component only has 2 states - checked and unchecked. Clicking or tapping - * toggles the `sap.ui.webc.main.CheckBox` between checked and unchecked state. - * - * Usage: - * - * You can define the checkbox text with via the `text` property. If the text exceeds the available width, - * it is truncated by default. In case you prefer text to wrap, set the `wrappingType` property to "Normal". - * The touchable area for toggling the `sap.ui.webc.main.CheckBox` ends where the text ends. - * - * You can disable the `sap.ui.webc.main.CheckBox` by setting the `disabled` property to `true`, or use - * the `sap.ui.webc.main.CheckBox` in read-only mode by setting the `readonly` property to `true`. - * - * - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.CheckBox` exposes the following CSS Shadow Parts: - * - root - Used to style the outermost wrapper of the `sap.ui.webc.main.CheckBox` - * - * - * - * Keyboard Handling: - * - * The user can use the following keyboard shortcuts to toggle the checked state of the `sap.ui.webc.main.CheckBox`. - * - * - [SPACE, ENTER] - Toggles between different states: checked, not checked. - * - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class CheckBox extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `CheckBox`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $CheckBoxSettings - ); - /** - * Constructor for a new `CheckBox`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $CheckBoxSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.CheckBox with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.CheckBox. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.CheckBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.CheckBox` itself. - * - * Fired when the component checked state changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.CheckBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.CheckBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.CheckBox` itself. - * - * Fired when the component checked state changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.CheckBox` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.CheckBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getChecked checked}. - * - * Defines if the component is checked. - * - * **Note:** The property can be changed with user interaction, either by cliking/tapping on the component, - * or by pressing the Enter or Space key. - * - * Default value is `false`. - * - * - * @returns Value of property `checked` - */ - getChecked(): boolean; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIndeterminate indeterminate}. - * - * Defines whether the component is displayed as partially checked. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction - * and the resulting visual state depends on the values of the `indeterminate` and `checked` properties: - * - * If the component is checked and indeterminate, it will be displayed as partially checked If the - * component is checked and it is not indeterminate, it will be displayed as checked If the component - * is not checked, it will be displayed as not checked regardless value of the indeterminate attribute - * - * Default value is `false`. - * - * - * @returns Value of property `indeterminate` - */ - getIndeterminate(): boolean; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * - * - * **Note:** - * - * - * - `Warning` - * - `Error` - * - `None`(default) - * - `Success` - * - `Information` - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Gets current value of property {@link #getWrappingType wrappingType}. - * - * Defines whether the component text wraps when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * Default value is `None`. - * - * - * @returns Value of property `wrappingType` - */ - getWrappingType(): WrappingType; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getChecked checked}. - * - * Defines if the component is checked. - * - * **Note:** The property can be changed with user interaction, either by cliking/tapping on the component, - * or by pressing the Enter or Space key. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setChecked( - /** - * New value for property `checked` - */ - bChecked?: boolean - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIndeterminate indeterminate}. - * - * Defines whether the component is displayed as partially checked. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction - * and the resulting visual state depends on the values of the `indeterminate` and `checked` properties: - * - * If the component is checked and indeterminate, it will be displayed as partially checked If the - * component is checked and it is not indeterminate, it will be displayed as checked If the component - * is not checked, it will be displayed as not checked regardless value of the indeterminate attribute - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIndeterminate( - /** - * New value for property `indeterminate` - */ - bIndeterminate?: boolean - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * - * - * **Note:** - * - * - * - `Warning` - * - `Error` - * - `None`(default) - * - `Success` - * - `Information` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Sets a new value for property {@link #getWrappingType wrappingType}. - * - * Defines whether the component text wraps when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWrappingType( - /** - * New value for property `wrappingType` - */ - sWrappingType?: WrappingType | keyof typeof WrappingType - ): this; - } - /** - * Describes the settings that can be provided to the CheckBox constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $CheckBoxSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines if the component is checked. - * - * **Note:** The property can be changed with user interaction, either by cliking/tapping on the component, - * or by pressing the Enter or Space key. - */ - checked?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is displayed as partially checked. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction - * and the resulting visual state depends on the values of the `indeterminate` and `checked` properties: - * - * If the component is checked and indeterminate, it will be displayed as partially checked If the - * component is checked and it is not indeterminate, it will be displayed as checked If the component - * is not checked, it will be displayed as not checked regardless value of the indeterminate attribute - */ - indeterminate?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - * - * - * - * **Note:** - * - * - * - `Warning` - * - `Error` - * - `None`(default) - * - `Success` - * - `Information` - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component text wraps when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - */ - wrappingType?: - | (WrappingType | keyof typeof WrappingType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component checked state changes. - */ - change?: (oEvent: Event) => void; - } - - /** - * Parameters of the CheckBox#change event. - */ - export interface CheckBox$ChangeEventParameters {} - - /** - * Event object of the CheckBox#change event. - */ - export type CheckBox$ChangeEvent = Event< - CheckBox$ChangeEventParameters, - CheckBox - >; -} - -declare module "sap/ui/webc/main/ColorPalette" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IColorPaletteItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { AggregationBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The `sap.ui.webc.main.ColorPalette` provides the users with a range of predefined colors. The - * colors are fixed and do not change with the theme. - * - * Usage: - * - * The `sap.ui.webc.main.ColorPalette` is meant for users that need to select a color from a predefined - * set. To define the colors, use the `sap.ui.webc.main.ColorPaletteItem` component inside the default slot - * of the `sap.ui.webc.main.ColorPalette`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ColorPalette extends WebComponent { - /** - * Constructor for a new `ColorPalette`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ColorPaletteSettings - ); - /** - * Constructor for a new `ColorPalette`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ColorPaletteSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ColorPalette with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ColorPalette. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some color to the aggregation {@link #getColors colors}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addColor( - /** - * The color to add; if empty, nothing is inserted - */ - oColor: IColorPaletteItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.ColorPalette`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ColorPalette` itself. - * - * Fired when the user selects a color. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ColorPalette$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ColorPalette` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.ColorPalette`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ColorPalette` itself. - * - * Fired when the user selects a color. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ColorPalette$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ColorPalette` itself - */ - oListener?: object - ): this; - /** - * Destroys all the colors in the aggregation {@link #getColors colors}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyColors(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.ColorPalette`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ColorPalette$ItemClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:itemClick itemClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ColorPalette$ItemClickEventParameters - ): this; - /** - * Gets content of aggregation {@link #getColors colors}. - * - * Defines the `sap.ui.webc.main.ColorPaletteItem` elements. - */ - getColors(): IColorPaletteItem[]; - /** - * Checks for the provided `sap.ui.webc.main.IColorPaletteItem` in the aggregation {@link #getColors colors}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfColor( - /** - * The color whose index is looked for - */ - oColor: IColorPaletteItem - ): int; - /** - * Inserts a color into the aggregation {@link #getColors colors}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertColor( - /** - * The color to insert; if empty, nothing is inserted - */ - oColor: IColorPaletteItem, - /** - * The `0`-based index the color should be inserted at; for a negative value of `iIndex`, the color is inserted - * at position 0; for a value greater than the current size of the aggregation, the color is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getColors colors}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllColors(): IColorPaletteItem[]; - /** - * Removes a color from the aggregation {@link #getColors colors}. - * - * - * @returns The removed color or `null` - */ - removeColor( - /** - * The color to remove or its index or id - */ - vColor: int | string | IColorPaletteItem - ): IColorPaletteItem | null; - } - /** - * Describes the settings that can be provided to the ColorPalette constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ColorPaletteSettings extends $WebComponentSettings { - /** - * Defines the `sap.ui.webc.main.ColorPaletteItem` elements. - */ - colors?: - | IColorPaletteItem[] - | IColorPaletteItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the user selects a color. - */ - itemClick?: (oEvent: ColorPalette$ItemClickEvent) => void; - } - - /** - * Parameters of the ColorPalette#itemClick event. - */ - export interface ColorPalette$ItemClickEventParameters { - /** - * the selected color - */ - color?: string; - } - - /** - * Event object of the ColorPalette#itemClick event. - */ - export type ColorPalette$ItemClickEvent = Event< - ColorPalette$ItemClickEventParameters, - ColorPalette - >; -} - -declare module "sap/ui/webc/main/ColorPaletteItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IColorPaletteItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { CSSColor } from "sap/ui/core/library"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.ColorPaletteItem` component represents a color in the the `sap.ui.webc.main.ColorPalette`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ColorPaletteItem - extends WebComponent - implements IColorPaletteItem - { - __implements__sap_ui_webc_main_IColorPaletteItem: boolean; - /** - * Constructor for a new `ColorPaletteItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ColorPaletteItemSettings - ); - /** - * Constructor for a new `ColorPaletteItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ColorPaletteItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ColorPaletteItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ColorPaletteItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the colour of the component. - * - * **Note:** The value should be a valid CSS color. - * - * - * @returns Value of property `value` - */ - getValue(): CSSColor; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the colour of the component. - * - * **Note:** The value should be a valid CSS color. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue: CSSColor - ): this; - } - /** - * Describes the settings that can be provided to the ColorPaletteItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ColorPaletteItemSettings extends $WebComponentSettings { - /** - * Defines the colour of the component. - * - * **Note:** The value should be a valid CSS color. - */ - value?: CSSColor | PropertyBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/ColorPalettePopover" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IColorPaletteItem } from "sap/ui/webc/main/library"; - - import { CSSColor } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: Represents a predefined range of colors for easier selection. - * - * Overview The ColorPalettePopover provides the users with a slot to predefine colors. - * - * You can customize them with the use of the colors property. You can specify a defaultColor and display - * a "Default color" button for the user to choose directly. You can display a "More colors..." button that - * opens an additional color picker for the user to choose specific colors that are not present in the predefined - * range. - * - * Usage: - * - * The palette is intended for users, who don't want to check and remember the different values of the colors - * and spend large amount of time to configure the right color through the color picker. - * - * @since 1.97.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export default class ColorPalettePopover extends WebComponent { - /** - * Constructor for a new `ColorPalettePopover`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ColorPalettePopoverSettings - ); - /** - * Constructor for a new `ColorPalettePopover`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ColorPalettePopoverSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ColorPalettePopover with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ColorPalettePopover. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some color to the aggregation {@link #getColors colors}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addColor( - /** - * The color to add; if empty, nothing is inserted - */ - oColor: IColorPaletteItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.ColorPalettePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ColorPalettePopover` itself. - * - * Fired when the user selects a color. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ColorPalettePopover$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ColorPalettePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.ColorPalettePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ColorPalettePopover` itself. - * - * Fired when the user selects a color. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ColorPalettePopover$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ColorPalettePopover` - * itself - */ - oListener?: object - ): this; - /** - * Destroys all the colors in the aggregation {@link #getColors colors}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyColors(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.ColorPalettePopover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ColorPalettePopover$ItemClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:itemClick itemClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemClick( - /** - * Parameters to pass along with the event - */ - mParameters?: ColorPalettePopover$ItemClickEventParameters - ): this; - /** - * Gets content of aggregation {@link #getColors colors}. - * - * Defines the content of the component. - */ - getColors(): IColorPaletteItem[]; - /** - * Gets current value of property {@link #getDefaultColor defaultColor}. - * - * Defines the default color of the component. **Note:** The default color should be a part of the ColorPalette - * colors - * - * - * @returns Value of property `defaultColor` - */ - getDefaultColor(): CSSColor; - /** - * Gets current value of property {@link #getShowDefaultColor showDefaultColor}. - * - * Defines whether the user can choose the default color from a button. - * - * Default value is `false`. - * - * - * @returns Value of property `showDefaultColor` - */ - getShowDefaultColor(): boolean; - /** - * Gets current value of property {@link #getShowMoreColors showMoreColors}. - * - * Defines whether the user can choose a custom color from a component. **Note:** In order to use this property - * you need to import the following module: `"@ui5/webcomponents/dist/features/ColorPaletteMoreColors.js"` - * - * Default value is `false`. - * - * - * @returns Value of property `showMoreColors` - */ - getShowMoreColors(): boolean; - /** - * Gets current value of property {@link #getShowRecentColors showRecentColors}. - * - * Defines whether the user can see the last used colors in the bottom of the component - * - * Default value is `false`. - * - * - * @returns Value of property `showRecentColors` - */ - getShowRecentColors(): boolean; - /** - * Checks for the provided `sap.ui.webc.main.IColorPaletteItem` in the aggregation {@link #getColors colors}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfColor( - /** - * The color whose index is looked for - */ - oColor: IColorPaletteItem - ): int; - /** - * Inserts a color into the aggregation {@link #getColors colors}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertColor( - /** - * The color to insert; if empty, nothing is inserted - */ - oColor: IColorPaletteItem, - /** - * The `0`-based index the color should be inserted at; for a negative value of `iIndex`, the color is inserted - * at position 0; for a value greater than the current size of the aggregation, the color is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getColors colors}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllColors(): IColorPaletteItem[]; - /** - * Removes a color from the aggregation {@link #getColors colors}. - * - * - * @returns The removed color or `null` - */ - removeColor( - /** - * The color to remove or its index or id - */ - vColor: int | string | IColorPaletteItem - ): IColorPaletteItem | null; - /** - * Sets a new value for property {@link #getDefaultColor defaultColor}. - * - * Defines the default color of the component. **Note:** The default color should be a part of the ColorPalette - * colors - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDefaultColor( - /** - * New value for property `defaultColor` - */ - sDefaultColor: CSSColor - ): this; - /** - * Sets a new value for property {@link #getShowDefaultColor showDefaultColor}. - * - * Defines whether the user can choose the default color from a button. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowDefaultColor( - /** - * New value for property `showDefaultColor` - */ - bShowDefaultColor?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowMoreColors showMoreColors}. - * - * Defines whether the user can choose a custom color from a component. **Note:** In order to use this property - * you need to import the following module: `"@ui5/webcomponents/dist/features/ColorPaletteMoreColors.js"` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowMoreColors( - /** - * New value for property `showMoreColors` - */ - bShowMoreColors?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowRecentColors showRecentColors}. - * - * Defines whether the user can see the last used colors in the bottom of the component - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowRecentColors( - /** - * New value for property `showRecentColors` - */ - bShowRecentColors?: boolean - ): this; - /** - * Shows the ColorPalettePopover. - */ - showAt( - /** - * the element that the popover is shown at - */ - opener: HTMLElement - ): void; - } - /** - * Describes the settings that can be provided to the ColorPalettePopover constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.97.0. This control is experimental and its API might change significantly. - */ - export interface $ColorPalettePopoverSettings extends $WebComponentSettings { - /** - * Defines the default color of the component. **Note:** The default color should be a part of the ColorPalette - * colors - */ - defaultColor?: CSSColor | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the user can choose the default color from a button. - */ - showDefaultColor?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the user can choose a custom color from a component. **Note:** In order to use this property - * you need to import the following module: `"@ui5/webcomponents/dist/features/ColorPaletteMoreColors.js"` - */ - showMoreColors?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the user can see the last used colors in the bottom of the component - */ - showRecentColors?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the component. - */ - colors?: - | IColorPaletteItem[] - | IColorPaletteItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the user selects a color. - */ - itemClick?: (oEvent: ColorPalettePopover$ItemClickEvent) => void; - } - - /** - * Parameters of the ColorPalettePopover#itemClick event. - */ - export interface ColorPalettePopover$ItemClickEventParameters { - /** - * the selected color - */ - color?: string; - } - - /** - * Event object of the ColorPalettePopover#itemClick event. - */ - export type ColorPalettePopover$ItemClickEvent = Event< - ColorPalettePopover$ItemClickEventParameters, - ColorPalettePopover - >; -} - -declare module "sap/ui/webc/main/ColorPicker" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Event from "sap/ui/base/Event"; - - import { CSSColor } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.ColorPicker` allows users to choose any color and provides different - * input options for selecting colors. - * - * Usage: - * - * When to use: - * - users need to select any color freely. - * - * When not to use:: - * - Users need to select one color from a predefined set of colors. Use the ColorPalette component instead. - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ColorPicker extends WebComponent { - /** - * Constructor for a new `ColorPicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ColorPickerSettings - ); - /** - * Constructor for a new `ColorPicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ColorPickerSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ColorPicker with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ColorPicker. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.ColorPicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ColorPicker` itself. - * - * Fired when the the selected color is changed - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ColorPicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.ColorPicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ColorPicker` itself. - * - * Fired when the the selected color is changed - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ColorPicker` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.ColorPicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getColor color}. - * - * Defines the currently selected color of the component. - * - * **Note**: use HEX, RGB, RGBA, HSV formats or a CSS color name when modifying this property. - * - * - * @returns Value of property `color` - */ - getColor(): CSSColor; - /** - * Sets a new value for property {@link #getColor color}. - * - * Defines the currently selected color of the component. - * - * **Note**: use HEX, RGB, RGBA, HSV formats or a CSS color name when modifying this property. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setColor( - /** - * New value for property `color` - */ - sColor: CSSColor - ): this; - } - /** - * Describes the settings that can be provided to the ColorPicker constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ColorPickerSettings extends $WebComponentSettings { - /** - * Defines the currently selected color of the component. - * - * **Note**: use HEX, RGB, RGBA, HSV formats or a CSS color name when modifying this property. - */ - color?: CSSColor | PropertyBindingInfo | `{${string}}`; - - /** - * Fired when the the selected color is changed - */ - change?: (oEvent: Event) => void; - } - - /** - * Parameters of the ColorPicker#change event. - */ - export interface ColorPicker$ChangeEventParameters {} - - /** - * Event object of the ColorPicker#change event. - */ - export type ColorPicker$ChangeEvent = Event< - ColorPicker$ChangeEventParameters, - ColorPicker - >; -} - -declare module "sap/ui/webc/main/ComboBox" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { - IIcon, - IComboBoxItem, - ComboBoxFilter, - } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.ComboBox` component represents a drop-down menu with a list of the available options - * and a text input field to narrow down the options. - * - * It is commonly used to enable users to select an option from a predefined list. - * - * Structure: The `sap.ui.webc.main.ComboBox` consists of the following elements: - * - * - * - Input field - displays the selected option or a custom user entry. Users can type to narrow down - * the list or enter their own value. - * - Drop-down arrow - expands\collapses the option list. - * - Option list - the list of available options. - * - * Keyboard Handling: - * - * The `sap.ui.webc.main.ComboBox` provides advanced keyboard handling. - * - * - * - * - [F4], [ALT]+[UP], or [ALT]+[DOWN] - Toggles the picker. - * - [ESC] - Closes the picker, if open. If closed, cancels changes and reverts the typed in value. - * - [ENTER] or [RETURN] - If picker is open, takes over the currently selected item and closes it. - * - [DOWN] - Selects the next matching item in the picker. - * - [UP] - Selects the previous matching item in the picker. - * - [PAGEDOWN] - Moves selection down by page size (10 items by default). - * - [PAGEUP] - Moves selection up by page size (10 items by default). - * - [HOME] - If focus is in the ComboBox, moves cursor at the beginning of text. If focus is in the picker, - * selects the first item. - * - [END] - If focus is in the ComboBox, moves cursor at the end of text. If focus is in the picker, - * selects the last item. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ComboBox extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `ComboBox`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ComboBoxSettings - ); - /** - * Constructor for a new `ComboBox`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ComboBoxSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ComboBox with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ComboBox. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some icon to the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addIcon( - /** - * The icon to add; if empty, nothing is inserted - */ - oIcon: IIcon - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IComboBoxItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.ComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ComboBox` itself. - * - * Fired when the input operation has finished by pressing Enter, focusout or an item is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.ComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ComboBox` itself. - * - * Fired when the input operation has finished by pressing Enter, focusout or an item is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.ComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ComboBox` itself. - * - * Fired when typing in input. - * - * **Note:** filterValue property is updated, input is changed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.ComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ComboBox` itself. - * - * Fired when typing in input. - * - * **Note:** filterValue property is updated, input is changed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.ComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ComboBox` itself. - * - * Fired when selection is changed by user interaction - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ComboBox$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.ComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ComboBox` itself. - * - * Fired when selection is changed by user interaction - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ComboBox$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ComboBox` itself - */ - oListener?: object - ): this; - /** - * Destroys all the icon in the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyIcon(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.ComboBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.ComboBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.main.ComboBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ComboBox$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: ComboBox$SelectionChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getFilter filter}. - * - * Defines the filter type of the component. - * - * Default value is `StartsWithPerTerm`. - * - * - * @returns Value of property `filter` - */ - getFilter(): ComboBoxFilter; - /** - * Gets content of aggregation {@link #getIcon icon}. - * - * Defines the icon to be displayed in the input field. - */ - getIcon(): IIcon[]; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the component items. - */ - getItems(): IComboBoxItem[]; - /** - * Gets current value of property {@link #getLoading loading}. - * - * Indicates whether a loading indicator should be shown in the picker. - * - * Default value is `false`. - * - * - * @returns Value of property `loading` - */ - getLoading(): boolean; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the value of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.IIcon` in the aggregation {@link #getIcon icon}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfIcon( - /** - * The icon whose index is looked for - */ - oIcon: IIcon - ): int; - /** - * Checks for the provided `sap.ui.webc.main.IComboBoxItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IComboBoxItem - ): int; - /** - * Inserts a icon into the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertIcon( - /** - * The icon to insert; if empty, nothing is inserted - */ - oIcon: IIcon, - /** - * The `0`-based index the icon should be inserted at; for a negative value of `iIndex`, the icon is inserted - * at position 0; for a value greater than the current size of the aggregation, the icon is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IComboBoxItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getIcon icon}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllIcon(): IIcon[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IComboBoxItem[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a icon from the aggregation {@link #getIcon icon}. - * - * - * @returns The removed icon or `null` - */ - removeIcon( - /** - * The icon to remove or its index or id - */ - vIcon: int | string | IIcon - ): IIcon | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IComboBoxItem - ): IComboBoxItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getFilter filter}. - * - * Defines the filter type of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `StartsWithPerTerm`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFilter( - /** - * New value for property `filter` - */ - sFilter?: ComboBoxFilter | keyof typeof ComboBoxFilter - ): this; - /** - * Sets a new value for property {@link #getLoading loading}. - * - * Indicates whether a loading indicator should be shown in the picker. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLoading( - /** - * New value for property `loading` - */ - bLoading?: boolean - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the value of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the ComboBox constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ComboBoxSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the filter type of the component. - */ - filter?: - | (ComboBoxFilter | keyof typeof ComboBoxFilter) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Indicates whether a loading indicator should be shown in the picker. - */ - loading?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a short hint intended to aid the user with data entry when the component has no value. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the value of the component. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon to be displayed in the input field. - */ - icon?: IIcon[] | IIcon | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the component items. - */ - items?: - | IComboBoxItem[] - | IComboBoxItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter, focusout or an item is selected. - */ - change?: (oEvent: Event) => void; - - /** - * Fired when typing in input. - * - * **Note:** filterValue property is updated, input is changed. - */ - input?: (oEvent: Event) => void; - - /** - * Fired when selection is changed by user interaction - */ - selectionChange?: (oEvent: ComboBox$SelectionChangeEvent) => void; - } - - /** - * Parameters of the ComboBox#change event. - */ - export interface ComboBox$ChangeEventParameters {} - - /** - * Event object of the ComboBox#change event. - */ - export type ComboBox$ChangeEvent = Event< - ComboBox$ChangeEventParameters, - ComboBox - >; - - /** - * Parameters of the ComboBox#input event. - */ - export interface ComboBox$InputEventParameters {} - - /** - * Event object of the ComboBox#input event. - */ - export type ComboBox$InputEvent = Event< - ComboBox$InputEventParameters, - ComboBox - >; - - /** - * Parameters of the ComboBox#selectionChange event. - */ - export interface ComboBox$SelectionChangeEventParameters { - /** - * item to be selected. - */ - item?: IComboBoxItem; - } - - /** - * Event object of the ComboBox#selectionChange event. - */ - export type ComboBox$SelectionChangeEvent = Event< - ComboBox$SelectionChangeEventParameters, - ComboBox - >; -} - -declare module "sap/ui/webc/main/ComboBoxGroupItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IComboBoxItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.ComboBoxGroupItem` is type of suggestion item, that can be used to split the `sap.ui.webc.main.ComboBox` - * suggestions into groups. - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class ComboBoxGroupItem - extends WebComponent - implements IComboBoxItem - { - __implements__sap_ui_webc_main_IComboBoxItem: boolean; - /** - * Constructor for a new `ComboBoxGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ComboBoxGroupItemSettings - ); - /** - * Constructor for a new `ComboBoxGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ComboBoxGroupItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ComboBoxGroupItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ComboBoxGroupItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the ComboBoxGroupItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $ComboBoxGroupItemSettings extends $WebComponentSettings { - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/ComboBoxItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IComboBoxItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.ComboBoxItem` represents the item for a `sap.ui.webc.main.ComboBox`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ComboBoxItem - extends WebComponent - implements IComboBoxItem - { - __implements__sap_ui_webc_main_IComboBoxItem: boolean; - /** - * Constructor for a new `ComboBoxItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ComboBoxItemSettings - ); - /** - * Constructor for a new `ComboBoxItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ComboBoxItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ComboBoxItem with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ComboBoxItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the additional text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the additional text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the ComboBoxItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ComboBoxItemSettings extends $WebComponentSettings { - /** - * Defines the additional text of the component. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/CustomListItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IListItem, IButton, ListItemType } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * A component to be used as custom list item within the `sap.ui.webc.main.List` the same way as the standard - * `sap.ui.webc.main.StandardListItem`. - * - * The component accepts arbitrary HTML content to allow full customization. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.CustomListItem` exposes the following CSS Shadow Parts: - * - native-li - Used to style the main li tag of the list item - * - content - Used to style the content area of the list item - * - detail-button - Used to style the button rendered when the list item is of type detail - * - delete-button - Used to style the button rendered when the list item is in delete mode - * - radio - Used to style the radio button rendered when the list item is in single selection mode - * - checkbox - Used to style the checkbox rendered when the list item is in multiple selection mode - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class CustomListItem - extends WebComponent - implements IListItem - { - __implements__sap_ui_webc_main_IListItem: boolean; - /** - * Constructor for a new `CustomListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $CustomListItemSettings - ); - /** - * Constructor for a new `CustomListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $CustomListItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.CustomListItem with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.CustomListItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.CustomListItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.CustomListItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.CustomListItem` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.CustomListItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.CustomListItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.CustomListItem` itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys the deleteButton in the aggregation {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyDeleteButton(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.CustomListItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachDetailClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:detailClick detailClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireDetailClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the component. - */ - getContent(): Control[]; - /** - * Gets content of aggregation {@link #getDeleteButton deleteButton}. - * - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - getDeleteButton(): IButton; - /** - * Gets current value of property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * - * @returns Value of property `navigated` - */ - getNavigated(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * Default value is `Active`. - * - * - * @returns Value of property `type` - */ - getType(): ListItemType; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets the aggregated {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDeleteButton( - /** - * The deleteButton to set - */ - oDeleteButton: IButton - ): this; - /** - * Sets a new value for property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNavigated( - /** - * New value for property `navigated` - */ - bNavigated: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Active`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ListItemType | keyof typeof ListItemType - ): this; - } - /** - * Describes the settings that can be provided to the CustomListItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $CustomListItemSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - */ - navigated?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - */ - type?: - | (ListItemType | keyof typeof ListItemType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the content of the component. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - deleteButton?: IButton; - - /** - * Fired when the user clicks on the detail button when type is `Detail`. - */ - detailClick?: (oEvent: Event) => void; - } - - /** - * Parameters of the CustomListItem#detailClick event. - */ - export interface CustomListItem$DetailClickEventParameters {} - - /** - * Event object of the CustomListItem#detailClick event. - */ - export type CustomListItem$DetailClickEvent = Event< - CustomListItem$DetailClickEventParameters, - CustomListItem - >; -} - -declare module "sap/ui/webc/main/DatePicker" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import CalendarType from "sap/ui/core/CalendarType"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `sap.ui.webc.main.DatePicker` component provides an input field with assigned calendar which opens - * on user action. The `sap.ui.webc.main.DatePicker` allows users to select a localized date using touch, - * mouse, or keyboard input. It consists of two parts: the date input field and the date picker. - * - * Usage: - * - * The user can enter a date by: - * - Using the calendar that opens in a popup - * - Typing it in directly in the input field - * - * When the user makes an entry and presses the enter key, the calendar shows the corresponding date. When - * the user directly triggers the calendar display, the actual date is displayed. - * - * Formatting: - * - * If a date is entered by typing it into the input field, it must fit to the used date format. - * - * Supported format options are pattern-based on Unicode LDML Date Format notation. For more information, - * see {@link http://unicode.org/reports/tr35/#Date_Field_Symbol_Table UTS #35: Unicode Locale Data Markup Language}. - * - * - * For example, if the `format-pattern` is "yyyy-MM-dd", a valid value string is "2015-07-30" and the same - * is displayed in the input. - * - * Keyboard Handling: The `sap.ui.webc.main.DatePicker` provides advanced keyboard handling. If the `sap.ui.webc.main.DatePicker` - * is focused, you can open or close the drop-down by pressing `F4`, `ALT+UP` or `ALT+DOWN` keys. Once the - * drop-down is opened, you can use the `UP`, `DOWN`, `LEFT`, `RIGHT` arrow keys to navigate through the - * dates and select one by pressing the `Space` or `Enter` keys. Moreover you can use TAB to reach the buttons - * for changing month and year. - * - * - * If the `sap.ui.webc.main.DatePicker` input field is focused and its corresponding picker dialog is not - * opened, then users can increment or decrement the date referenced by `dateValue` property by using the - * following shortcuts: - * - * - * - * - [PAGEDOWN] - Decrements the corresponding day of the month by one - * - [SHIFT] + [PAGEDOWN] - Decrements the corresponding month by one - * - [SHIFT] + [CTRL] + [PAGEDOWN] - Decrements the corresponding year by one - * - [PAGEUP] - Increments the corresponding day of the month by one - * - [SHIFT] + [PAGEUP] - Increments the corresponding month by one - * - [SHIFT] + [CTRL] + [PAGEUP] - Increments the corresponding year by one - * - * Calendar types: The component supports several calendar types - Gregorian, Buddhist, Islamic, Japanese - * and Persian. By default the Gregorian Calendar is used. In order to use the Buddhist, Islamic, Japanese - * or Persian calendar, you need to set the `primaryCalendarType` property and import one or more of the - * following modules: - * - * - * - * Or, you can use the global configuration and set the `calendarType` key: - * - * ```javascript - * ``` - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class DatePicker extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `DatePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $DatePickerSettings - ); - /** - * Constructor for a new `DatePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $DatePickerSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.DatePicker with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.DatePicker. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.DatePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DatePicker` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DatePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DatePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.DatePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DatePicker` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DatePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DatePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.DatePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DatePicker` itself. - * - * Fired when the value of the component is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DatePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DatePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.DatePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DatePicker` itself. - * - * Fired when the value of the component is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DatePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DatePicker` itself - */ - oListener?: object - ): this; - /** - * Closes the picker. - */ - closePicker(): void; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.DatePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: DatePicker$ChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.DatePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: DatePicker$InputEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: DatePicker$ChangeEventParameters - ): boolean; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: DatePicker$InputEventParameters - ): boolean; - /** - * Formats a Java Script date object into a string representing a locale date according to the `formatPattern` - * property of the DatePicker instance - */ - formatValue( - /** - * A Java Script date object to be formatted as string - */ - date: Date - ): void; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the aria-label attribute for the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Returns the currently selected date represented as a Local JavaScript Date instance. - */ - getDateValue(): void; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * Default value is `empty string`. - * - * - * @returns Value of property `formatPattern` - */ - getFormatPattern(): string; - /** - * Gets current value of property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * Default value is `false`. - * - * - * @returns Value of property `hideWeekNumbers` - */ - getHideWeekNumbers(): boolean; - /** - * Gets current value of property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `maxDate` - */ - getMaxDate(): string; - /** - * Gets current value of property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `minDate` - */ - getMinDate(): string; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * Default value is `undefined`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * - * @returns Value of property `primaryCalendarType` - */ - getPrimaryCalendarType(): CalendarType; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * Default value is `undefined`. - * - * - * @returns Value of property `secondaryCalendarType` - */ - getSecondaryCalendarType(): CalendarType; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines a formatted date value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks if a date is between the minimum and maximum date. - */ - isInValidRange( - /** - * A value to be checked - */ - value: string - ): void; - /** - * Checks if the picker is open. - */ - isOpen(): void; - /** - * Checks if a value is valid against the current date format of the DatePicker. - */ - isValid( - /** - * A value to be tested against the current date format - */ - value: string - ): void; - /** - * Opens the picker. - */ - openPicker(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the aria-label attribute for the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFormatPattern( - /** - * New value for property `formatPattern` - */ - sFormatPattern?: string - ): this; - /** - * Sets a new value for property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideWeekNumbers( - /** - * New value for property `hideWeekNumbers` - */ - bHideWeekNumbers?: boolean - ): this; - /** - * Sets a new value for property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMaxDate( - /** - * New value for property `maxDate` - */ - sMaxDate?: string - ): this; - /** - * Sets a new value for property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMinDate( - /** - * New value for property `minDate` - */ - sMinDate?: string - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPrimaryCalendarType( - /** - * New value for property `primaryCalendarType` - */ - sPrimaryCalendarType: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSecondaryCalendarType( - /** - * New value for property `secondaryCalendarType` - */ - sSecondaryCalendarType?: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines a formatted date value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the DatePicker constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $DatePickerSettings extends $WebComponentSettings { - /** - * Defines the aria-label attribute for the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the format, displayed in the input field. - */ - formatPattern?: string | PropertyBindingInfo; - - /** - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - */ - hideWeekNumbers?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - maxDate?: string | PropertyBindingInfo; - - /** - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - minDate?: string | PropertyBindingInfo; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - */ - primaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines whether the component is displayed as read-only. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - */ - secondaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines a formatted date value. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter or on focusout. - */ - change?: (oEvent: DatePicker$ChangeEvent) => void; - - /** - * Fired when the value of the component is changed at each key stroke. - */ - input?: (oEvent: DatePicker$InputEvent) => void; - } - - /** - * Parameters of the DatePicker#change event. - */ - export interface DatePicker$ChangeEventParameters { - /** - * The submitted value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the DatePicker#change event. - */ - export type DatePicker$ChangeEvent = Event< - DatePicker$ChangeEventParameters, - DatePicker - >; - - /** - * Parameters of the DatePicker#input event. - */ - export interface DatePicker$InputEventParameters { - /** - * The submitted value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the DatePicker#input event. - */ - export type DatePicker$InputEvent = Event< - DatePicker$InputEventParameters, - DatePicker - >; -} - -declare module "sap/ui/webc/main/DateRangePicker" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import CalendarType from "sap/ui/core/CalendarType"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The DateRangePicker enables the users to enter a localized date range using touch, mouse, keyboard - * input, or by selecting a date range in the calendar. - * - * Keyboard Handling: The `sap.ui.webc.main.DateRangePicker` provides advanced keyboard handling. - * - * - * When the `sap.ui.webc.main.DateRangePicker` input field is focused the user can increment or decrement - * respectively the range start or end date, depending on where the cursor is. The following shortcuts are - * available: - * - * - * - * - [PAGEDOWN] - Decrements the corresponding day of the month by one - * - [SHIFT] + [PAGEDOWN] - Decrements the corresponding month by one - * - [SHIFT] + [CTRL] + [PAGEDOWN] - Decrements the corresponding year by one - * - [PAGEUP] - Increments the corresponding day of the month by one - * - [SHIFT] + [PAGEUP] - Increments the corresponding month by one - * - [SHIFT] + [CTRL] + [PAGEUP] - Increments the corresponding year by one - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class DateRangePicker - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `DateRangePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $DateRangePickerSettings - ); - /** - * Constructor for a new `DateRangePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $DateRangePickerSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.DateRangePicker with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.DateRangePicker. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.DateRangePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateRangePicker` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateRangePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateRangePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.DateRangePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateRangePicker` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateRangePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateRangePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.DateRangePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateRangePicker` itself. - * - * Fired when the value of the component is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateRangePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateRangePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.DateRangePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateRangePicker` itself. - * - * Fired when the value of the component is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateRangePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateRangePicker` itself - */ - oListener?: object - ): this; - /** - * Closes the picker. - */ - closePicker(): void; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.DateRangePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: DateRangePicker$ChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.DateRangePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: DateRangePicker$InputEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: DateRangePicker$ChangeEventParameters - ): boolean; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: DateRangePicker$InputEventParameters - ): boolean; - /** - * Formats a Java Script date object into a string representing a locale date according to the `formatPattern` - * property of the DatePicker instance - */ - formatValue( - /** - * A Java Script date object to be formatted as string - */ - date: Date - ): void; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the aria-label attribute for the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Returns the **Note:** The getter method is inherited and not supported. If called it will return an empty - * value. - */ - getDateValue(): void; - /** - * Returns the **Note:** The getter method is inherited and not supported. If called it will return an empty - * value. - */ - getDateValueUTC(): void; - /** - * Gets current value of property {@link #getDelimiter delimiter}. - * - * Determines the symbol which separates the dates. If not supplied, the default time interval delimiter - * for the current locale will be used. - * - * Default value is `"-"`. - * - * - * @returns Value of property `delimiter` - */ - getDelimiter(): string; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Returns the end date of the currently selected range as JavaScript Date instance. - */ - getEndDateValue(): void; - /** - * Gets current value of property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * Default value is `empty string`. - * - * - * @returns Value of property `formatPattern` - */ - getFormatPattern(): string; - /** - * Gets current value of property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * Default value is `false`. - * - * - * @returns Value of property `hideWeekNumbers` - */ - getHideWeekNumbers(): boolean; - /** - * Gets current value of property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `maxDate` - */ - getMaxDate(): string; - /** - * Gets current value of property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `minDate` - */ - getMinDate(): string; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * Default value is `undefined`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * - * @returns Value of property `primaryCalendarType` - */ - getPrimaryCalendarType(): CalendarType; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * Default value is `undefined`. - * - * - * @returns Value of property `secondaryCalendarType` - */ - getSecondaryCalendarType(): CalendarType; - /** - * Returns the start date of the currently selected range as JavaScript Date instance. - */ - getStartDateValue(): void; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines a formatted date value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks if a date is between the minimum and maximum date. - */ - isInValidRange( - /** - * A value to be checked - */ - value: string - ): void; - /** - * Checks if the picker is open. - */ - isOpen(): void; - /** - * Checks if a value is valid against the current date format of the DatePicker. - */ - isValid( - /** - * A value to be tested against the current date format - */ - value: string - ): void; - /** - * Opens the picker. - */ - openPicker(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the aria-label attribute for the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getDelimiter delimiter}. - * - * Determines the symbol which separates the dates. If not supplied, the default time interval delimiter - * for the current locale will be used. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `"-"`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDelimiter( - /** - * New value for property `delimiter` - */ - sDelimiter?: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFormatPattern( - /** - * New value for property `formatPattern` - */ - sFormatPattern?: string - ): this; - /** - * Sets a new value for property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideWeekNumbers( - /** - * New value for property `hideWeekNumbers` - */ - bHideWeekNumbers?: boolean - ): this; - /** - * Sets a new value for property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMaxDate( - /** - * New value for property `maxDate` - */ - sMaxDate?: string - ): this; - /** - * Sets a new value for property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMinDate( - /** - * New value for property `minDate` - */ - sMinDate?: string - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPrimaryCalendarType( - /** - * New value for property `primaryCalendarType` - */ - sPrimaryCalendarType: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSecondaryCalendarType( - /** - * New value for property `secondaryCalendarType` - */ - sSecondaryCalendarType?: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines a formatted date value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the DateRangePicker constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $DateRangePickerSettings extends $WebComponentSettings { - /** - * Defines the aria-label attribute for the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Determines the symbol which separates the dates. If not supplied, the default time interval delimiter - * for the current locale will be used. - */ - delimiter?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the format, displayed in the input field. - */ - formatPattern?: string | PropertyBindingInfo; - - /** - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - */ - hideWeekNumbers?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - maxDate?: string | PropertyBindingInfo; - - /** - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - minDate?: string | PropertyBindingInfo; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - */ - primaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines whether the component is displayed as read-only. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - */ - secondaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines a formatted date value. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter or on focusout. - */ - change?: (oEvent: DateRangePicker$ChangeEvent) => void; - - /** - * Fired when the value of the component is changed at each key stroke. - */ - input?: (oEvent: DateRangePicker$InputEvent) => void; - } - - /** - * Parameters of the DateRangePicker#change event. - */ - export interface DateRangePicker$ChangeEventParameters { - /** - * The submitted value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the DateRangePicker#change event. - */ - export type DateRangePicker$ChangeEvent = Event< - DateRangePicker$ChangeEventParameters, - DateRangePicker - >; - - /** - * Parameters of the DateRangePicker#input event. - */ - export interface DateRangePicker$InputEventParameters { - /** - * The submitted value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the DateRangePicker#input event. - */ - export type DateRangePicker$InputEvent = Event< - DateRangePicker$InputEventParameters, - DateRangePicker - >; -} - -declare module "sap/ui/webc/main/DateTimePicker" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import CalendarType from "sap/ui/core/CalendarType"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The `DateTimePicker` component alows users to select both date (day, month and year) and time - * (hours, minutes and seconds) and for the purpose it consists of input field and Date/Time picker. - * - * Usage: - * - * Use the `DateTimePicker` if you need a combined date and time input component. Don't use it if you want - * to use either date, or time value. In this case, use the `DatePicker` or the `TimePicker` components - * instead. - * - * The user can set date/time by: - * - using the calendar and the time selectors - * - typing in the input field - * - * Programmatically, to set date/time for the `DateTimePicker`, use the `value` property - * - * Formatting: - * - * The value entered by typing into the input field must fit to the used date/time format. - * - * Supported format options are pattern-based on Unicode LDML Date Format notation. For more information, - * see {@link https://unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table UTS #35: Unicode Locale Data Markup Language}. - * - * - * **Example:** the following format `dd/MM/yyyy, hh:mm:ss aa` corresponds the `13/04/2020, 03:16:16 AM` - * value. - * The small 'h' defines "12" hours format and the "aa" symbols - "AM/PM" time periods. - * - * - * - * **Example:** the following format `dd/MM/yyyy, HH:mm:ss` corresponds the `13/04/2020, 15:16:16` value. - * - * The capital 'H' indicates "24" hours format. - * - * - * - * **Note:** If the `formatPattern` does NOT include time, the `DateTimePicker` will fallback to the default - * time format according to the locale. - * - * - * - * **Note:** If no placeholder is set to the `DateTimePicker`, the current `formatPattern` is displayed - * as a placeholder. If another placeholder is needed, it must be set or in case no placeholder is needed - * - it can be set to an empty string. - * - * - * - * **Note:** If the user input does NOT match the `formatPattern`, the `DateTimePicker` makes an attempt - * to parse it based on the locale settings. - * - * Responsive behavior: - * - * The `DateTimePicker` is responsive and fully adapts to all devices. For larger screens, such as tablet - * or desktop, it is displayed as a popover, while on phone devices, it is displayed full screen. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class DateTimePicker - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `DateTimePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $DateTimePickerSettings - ); - /** - * Constructor for a new `DateTimePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $DateTimePickerSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.DateTimePicker with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.DateTimePicker. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.DateTimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateTimePicker` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateTimePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateTimePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.DateTimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateTimePicker` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateTimePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateTimePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.DateTimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateTimePicker` itself. - * - * Fired when the value of the component is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateTimePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateTimePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.DateTimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.DateTimePicker` itself. - * - * Fired when the value of the component is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: DateTimePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.DateTimePicker` itself - */ - oListener?: object - ): this; - /** - * Closes the picker. - */ - closePicker(): void; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.DateTimePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: DateTimePicker$ChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.DateTimePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: DateTimePicker$InputEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: DateTimePicker$ChangeEventParameters - ): boolean; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: DateTimePicker$InputEventParameters - ): boolean; - /** - * Formats a Java Script date object into a string representing a locale date according to the `formatPattern` - * property of the DatePicker instance - */ - formatValue( - /** - * A Java Script date object to be formatted as string - */ - date: Date - ): void; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the aria-label attribute for the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Returns the currently selected date represented as a Local JavaScript Date instance. - */ - getDateValue(): void; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * Default value is `empty string`. - * - * - * @returns Value of property `formatPattern` - */ - getFormatPattern(): string; - /** - * Gets current value of property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * Default value is `false`. - * - * - * @returns Value of property `hideWeekNumbers` - */ - getHideWeekNumbers(): boolean; - /** - * Gets current value of property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `maxDate` - */ - getMaxDate(): string; - /** - * Gets current value of property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * Default value is `empty string`. - * - * - * @returns Value of property `minDate` - */ - getMinDate(): string; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * Default value is `undefined`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * - * @returns Value of property `primaryCalendarType` - */ - getPrimaryCalendarType(): CalendarType; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * Default value is `undefined`. - * - * - * @returns Value of property `secondaryCalendarType` - */ - getSecondaryCalendarType(): CalendarType; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines a formatted date value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks if a date is between the minimum and maximum date. - */ - isInValidRange( - /** - * A value to be checked - */ - value: string - ): void; - /** - * Checks if the picker is open. - */ - isOpen(): void; - /** - * Checks if a value is valid against the current date format of the DatePicker. - */ - isValid( - /** - * A value to be tested against the current date format - */ - value: string - ): void; - /** - * Opens the picker. - */ - openPicker(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the aria-label attribute for the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFormatPattern( - /** - * New value for property `formatPattern` - */ - sFormatPattern?: string - ): this; - /** - * Sets a new value for property {@link #getHideWeekNumbers hideWeekNumbers}. - * - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideWeekNumbers( - /** - * New value for property `hideWeekNumbers` - */ - bHideWeekNumbers?: boolean - ): this; - /** - * Sets a new value for property {@link #getMaxDate maxDate}. - * - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMaxDate( - /** - * New value for property `maxDate` - */ - sMaxDate?: string - ): this; - /** - * Sets a new value for property {@link #getMinDate minDate}. - * - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMinDate( - /** - * New value for property `minDate` - */ - sMinDate?: string - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getPrimaryCalendarType primaryCalendarType}. - * - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPrimaryCalendarType( - /** - * New value for property `primaryCalendarType` - */ - sPrimaryCalendarType: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getSecondaryCalendarType secondaryCalendarType}. - * - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSecondaryCalendarType( - /** - * New value for property `secondaryCalendarType` - */ - sSecondaryCalendarType?: CalendarType | keyof typeof CalendarType - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines a formatted date value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the DateTimePicker constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $DateTimePickerSettings extends $WebComponentSettings { - /** - * Defines the aria-label attribute for the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the format, displayed in the input field. - */ - formatPattern?: string | PropertyBindingInfo; - - /** - * Defines the visibility of the week numbers column. - * - * - * - * **Note:** For calendars other than Gregorian, the week numbers are not displayed regardless of what is - * set. - */ - hideWeekNumbers?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the maximum date available for selection. - * - * **Note:** If the formatPattern property is not set, the maxDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - maxDate?: string | PropertyBindingInfo; - - /** - * Determines the minimum date available for selection. - * - * **Note:** If the formatPattern property is not set, the minDate value must be provided in the ISO date - * format (YYYY-MM-dd). - */ - minDate?: string | PropertyBindingInfo; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Sets a calendar type used for display. If not set, the calendar type of the global configuration is used. - */ - primaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines whether the component is displayed as read-only. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the secondary calendar type. If not set, the calendar will only show the primary calendar type. - */ - secondaryCalendarType?: - | (CalendarType | keyof typeof CalendarType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines a formatted date value. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter or on focusout. - */ - change?: (oEvent: DateTimePicker$ChangeEvent) => void; - - /** - * Fired when the value of the component is changed at each key stroke. - */ - input?: (oEvent: DateTimePicker$InputEvent) => void; - } - - /** - * Parameters of the DateTimePicker#change event. - */ - export interface DateTimePicker$ChangeEventParameters { - /** - * The submitted value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the DateTimePicker#change event. - */ - export type DateTimePicker$ChangeEvent = Event< - DateTimePicker$ChangeEventParameters, - DateTimePicker - >; - - /** - * Parameters of the DateTimePicker#input event. - */ - export interface DateTimePicker$InputEventParameters { - /** - * The submitted value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the DateTimePicker#input event. - */ - export type DateTimePicker$InputEvent = Event< - DateTimePicker$InputEventParameters, - DateTimePicker - >; -} - -declare module "sap/ui/webc/main/Dialog" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID, CSSSize, ValueState } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { PopupAccessibleRole } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.Dialog` component is used to temporarily display some information in - * a size-limited window in front of the regular app screen. It is used to prompt the user for an action - * or a confirmation. The `sap.ui.webc.main.Dialog` interrupts the current app processing as it is the only - * focused UI element and the main screen is dimmed/blocked. The dialog combines concepts known from other - * technologies where the windows have names such as dialog box, dialog window, pop-up, pop-up window, alert - * box, or message box. - * - * The `sap.ui.webc.main.Dialog` is modal, which means that an user action is required before it is possible - * to return to the parent window. To open multiple dialogs, each dialog element should be separate in the - * markup. This will ensure the correct modal behavior. Avoid nesting dialogs within each other. The content - * of the `sap.ui.webc.main.Dialog` is fully customizable. - * - * Structure: A `sap.ui.webc.main.Dialog` consists of a header, content, and a footer for action buttons. - * The `sap.ui.webc.main.Dialog` is usually displayed at the center of the screen. Its position can be changed - * by the user. To enable this, you need to set the property `draggable` accordingly. - * - * Responsive Behavior: The `stretch` property can be used to stretch the `sap.ui.webc.main.Dialog` on full - * screen. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Dialog` exposes the following CSS Shadow Parts: - * - header - Used to style the header of the component - * - content - Used to style the content of the component - * - footer - Used to style the footer of the component **Note:** When a `ui5-bar` is used in the - * header or in the footer, you should remove the default dialog's paddings. - * For more information see the sample "Bar in Header/Footer". - * - * **Note:** We don't recommend nesting popup-like components (`sap.ui.webc.main.Dialog`, `sap.ui.webc.main.Popover`) - * inside `sap.ui.webc.main.Dialog`. Ideally you should create all popups on the same level inside your - * HTML page and just open them from one another, rather than nesting them. - * - * **Note:** We don't recommend nesting popup-like components (`sap.ui.webc.main.Dialog`, `sap.ui.webc.main.Popover`) - * inside other components containing z-index. This might break z-index management. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Dialog extends WebComponent { - /** - * Constructor for a new `Dialog`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $DialogSettings - ); - /** - * Constructor for a new `Dialog`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $DialogSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Dialog with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Dialog. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some footer to the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addFooter( - /** - * The footer to add; if empty, nothing is inserted - */ - oFooter: Control - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Focuses the element denoted by `initialFocus`, if provided, or the first focusable element otherwise. - */ - applyFocus(): void; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired after the component is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired after the component is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired after the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired after the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Dialog$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Dialog$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Dialog`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Dialog` itself. - * - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Dialog` itself - */ - oListener?: object - ): this; - /** - * Closes the popup. - */ - close(): void; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys all the footer in the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyFooter(): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Dialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Dialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Dialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Dialog$BeforeCloseEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Dialog`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:afterClose afterClose} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterClose( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:afterOpen afterOpen} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:beforeClose beforeClose} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeClose( - /** - * Parameters to pass along with the event - */ - mParameters?: Dialog$BeforeCloseEventParameters - ): boolean; - /** - * Fires event {@link #event:beforeOpen beforeOpen} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): boolean; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAccessibleRole accessibleRole}. - * - * Allows setting a custom role. - * - * Default value is `Dialog`. - * - * - * @returns Value of property `accessibleRole` - */ - getAccessibleRole(): PopupAccessibleRole; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the Popup. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getDraggable draggable}. - * - * Determines whether the component is draggable. If this property is set to true, the Dialog will be draggable - * by its header. - * - * **Note:** The component can be draggable only in desktop mode. - * - * **Note:** This property overrides the default HTML "draggable" attribute native behavior. When "draggable" - * is set to true, the native browser "draggable" behavior is prevented and only the Dialog custom logic - * ("draggable by its header") works. - * - * Default value is `false`. - * - * - * @returns Value of property `draggable` - */ - getDraggable(): boolean; - /** - * Gets content of aggregation {@link #getFooter footer}. - * - * Defines the footer HTML Element. - * - * **Note:** When a `ui5-bar` is used in the footer, you should remove the default dialog's paddings. - */ - getFooter(): Control[]; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the header HTML Element. - * - * **Note:** When a `ui5-bar` is used in the header, you should remove the default dialog's paddings. - * - * **Note:** If `header` slot is provided, the labelling of the dialog is a responsibility of the application - * developer. `accessibleName` should be used. - */ - getHeader(): Control[]; - /** - * Gets current value of property {@link #getHeaderText headerText}. - * - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - * - * Default value is `empty string`. - * - * - * @returns Value of property `headerText` - */ - getHeaderText(): string; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * ID of the element which is the current target of the association {@link #getInitialFocus initialFocus}, - * or `null`. - */ - getInitialFocus(): ID | null; - /** - * Gets current value of property {@link #getOpen open}. - * - * Indicates if the element is open - * - * Default value is `false`. - * - * - * @returns Value of property `open` - */ - getOpen(): boolean; - /** - * Gets current value of property {@link #getPreventFocusRestore preventFocusRestore}. - * - * Defines if the focus should be returned to the previously focused element, when the popup closes. - * - * Default value is `false`. - * - * - * @returns Value of property `preventFocusRestore` - */ - getPreventFocusRestore(): boolean; - /** - * Gets current value of property {@link #getResizable resizable}. - * - * Configures the component to be resizable. If this property is set to true, the Dialog will have a resize - * handle in its bottom right corner in LTR languages. In RTL languages, the resize handle will be placed - * in the bottom left corner. - * - * **Note:** The component can be resizable only in desktop mode. - * **Note:** Upon resizing, externally defined height and width styling will be ignored. - * - * Default value is `false`. - * - * - * @returns Value of property `resizable` - */ - getResizable(): boolean; - /** - * Gets current value of property {@link #getState state}. - * - * Defines the state of the `Dialog`. - * **Note:** If `"Error"` and `"Warning"` state is set, it will change the accessibility role to "alertdialog", - * if the accessibleRole property is set to `"Dialog"`. - * - * Default value is `None`. - * - * - * @returns Value of property `state` - */ - getState(): ValueState; - /** - * Gets current value of property {@link #getStretch stretch}. - * - * Determines whether the component should be stretched to fullscreen. - * - * **Note:** The component will be stretched to approximately 90% of the viewport. - * - * Default value is `false`. - * - * - * @returns Value of property `stretch` - */ - getStretch(): boolean; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getFooter footer}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfFooter( - /** - * The footer whose index is looked for - */ - oFooter: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a footer into the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertFooter( - /** - * The footer to insert; if empty, nothing is inserted - */ - oFooter: Control, - /** - * The `0`-based index the footer should be inserted at; for a negative value of `iIndex`, the footer is - * inserted at position 0; for a value greater than the current size of the aggregation, the footer is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Tells if the component is opened - */ - isOpen(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getFooter footer}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllFooter(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a footer from the aggregation {@link #getFooter footer}. - * - * - * @returns The removed footer or `null` - */ - removeFooter( - /** - * The footer to remove or its index or id - */ - vFooter: int | string | Control - ): Control | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAccessibleRole accessibleRole}. - * - * Allows setting a custom role. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Dialog`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleRole( - /** - * New value for property `accessibleRole` - */ - sAccessibleRole?: PopupAccessibleRole | keyof typeof PopupAccessibleRole - ): this; - /** - * Sets a new value for property {@link #getDraggable draggable}. - * - * Determines whether the component is draggable. If this property is set to true, the Dialog will be draggable - * by its header. - * - * **Note:** The component can be draggable only in desktop mode. - * - * **Note:** This property overrides the default HTML "draggable" attribute native behavior. When "draggable" - * is set to true, the native browser "draggable" behavior is prevented and only the Dialog custom logic - * ("draggable by its header") works. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDraggable( - /** - * New value for property `draggable` - */ - bDraggable?: boolean - ): this; - /** - * Sets a new value for property {@link #getHeaderText headerText}. - * - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderText( - /** - * New value for property `headerText` - */ - sHeaderText?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets the associated {@link #getInitialFocus initialFocus}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInitialFocus( - /** - * ID of an element which becomes the new target of this initialFocus association; alternatively, an element - * instance may be given - */ - oInitialFocus: ID | Control - ): this; - /** - * Sets a new value for property {@link #getOpen open}. - * - * Indicates if the element is open - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOpen( - /** - * New value for property `open` - */ - bOpen?: boolean - ): this; - /** - * Sets a new value for property {@link #getPreventFocusRestore preventFocusRestore}. - * - * Defines if the focus should be returned to the previously focused element, when the popup closes. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPreventFocusRestore( - /** - * New value for property `preventFocusRestore` - */ - bPreventFocusRestore?: boolean - ): this; - /** - * Sets a new value for property {@link #getResizable resizable}. - * - * Configures the component to be resizable. If this property is set to true, the Dialog will have a resize - * handle in its bottom right corner in LTR languages. In RTL languages, the resize handle will be placed - * in the bottom left corner. - * - * **Note:** The component can be resizable only in desktop mode. - * **Note:** Upon resizing, externally defined height and width styling will be ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setResizable( - /** - * New value for property `resizable` - */ - bResizable?: boolean - ): this; - /** - * Sets a new value for property {@link #getState state}. - * - * Defines the state of the `Dialog`. - * **Note:** If `"Error"` and `"Warning"` state is set, it will change the accessibility role to "alertdialog", - * if the accessibleRole property is set to `"Dialog"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setState( - /** - * New value for property `state` - */ - sState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getStretch stretch}. - * - * Determines whether the component should be stretched to fullscreen. - * - * **Note:** The component will be stretched to approximately 90% of the viewport. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStretch( - /** - * New value for property `stretch` - */ - bStretch?: boolean - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Shows the dialog. - */ - show( - /** - * Prevents applying the focus inside the popup - */ - preventInitialFocus: boolean - ): void; - } - /** - * Describes the settings that can be provided to the Dialog constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $DialogSettings extends $WebComponentSettings { - /** - * Defines the accessible name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Allows setting a custom role. - */ - accessibleRole?: - | (PopupAccessibleRole | keyof typeof PopupAccessibleRole) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines whether the component is draggable. If this property is set to true, the Dialog will be draggable - * by its header. - * - * **Note:** The component can be draggable only in desktop mode. - * - * **Note:** This property overrides the default HTML "draggable" attribute native behavior. When "draggable" - * is set to true, the native browser "draggable" behavior is prevented and only the Dialog custom logic - * ("draggable by its header") works. - */ - draggable?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - */ - headerText?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Indicates if the element is open - */ - open?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the focus should be returned to the previously focused element, when the popup closes. - */ - preventFocusRestore?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Configures the component to be resizable. If this property is set to true, the Dialog will have a resize - * handle in its bottom right corner in LTR languages. In RTL languages, the resize handle will be placed - * in the bottom left corner. - * - * **Note:** The component can be resizable only in desktop mode. - * **Note:** Upon resizing, externally defined height and width styling will be ignored. - */ - resizable?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the state of the `Dialog`. - * **Note:** If `"Error"` and `"Warning"` state is set, it will change the accessibility role to "alertdialog", - * if the accessibleRole property is set to `"Dialog"`. - */ - state?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines whether the component should be stretched to fullscreen. - * - * **Note:** The component will be stretched to approximately 90% of the viewport. - */ - stretch?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the Popup. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the footer HTML Element. - * - * **Note:** When a `ui5-bar` is used in the footer, you should remove the default dialog's paddings. - */ - footer?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the header HTML Element. - * - * **Note:** When a `ui5-bar` is used in the header, you should remove the default dialog's paddings. - * - * **Note:** If `header` slot is provided, the labelling of the dialog is a responsibility of the application - * developer. `accessibleName` should be used. - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Defines the ID of the HTML Element, which will get the initial focus. - */ - initialFocus?: Control | string; - - /** - * Fired after the component is closed. **This event does not bubble.** - */ - afterClose?: (oEvent: Event) => void; - - /** - * Fired after the component is opened. **This event does not bubble.** - */ - afterOpen?: (oEvent: Event) => void; - - /** - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - */ - beforeClose?: (oEvent: Dialog$BeforeCloseEvent) => void; - - /** - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - */ - beforeOpen?: (oEvent: Event) => void; - } - - /** - * Parameters of the Dialog#afterClose event. - */ - export interface Dialog$AfterCloseEventParameters {} - - /** - * Event object of the Dialog#afterClose event. - */ - export type Dialog$AfterCloseEvent = Event< - Dialog$AfterCloseEventParameters, - Dialog - >; - - /** - * Parameters of the Dialog#afterOpen event. - */ - export interface Dialog$AfterOpenEventParameters {} - - /** - * Event object of the Dialog#afterOpen event. - */ - export type Dialog$AfterOpenEvent = Event< - Dialog$AfterOpenEventParameters, - Dialog - >; - - /** - * Parameters of the Dialog#beforeClose event. - */ - export interface Dialog$BeforeCloseEventParameters { - /** - * Indicates that `ESC` key has triggered the event. - */ - escPressed?: boolean; - } - - /** - * Event object of the Dialog#beforeClose event. - */ - export type Dialog$BeforeCloseEvent = Event< - Dialog$BeforeCloseEventParameters, - Dialog - >; - - /** - * Parameters of the Dialog#beforeOpen event. - */ - export interface Dialog$BeforeOpenEventParameters {} - - /** - * Event object of the Dialog#beforeOpen event. - */ - export type Dialog$BeforeOpenEvent = Event< - Dialog$BeforeOpenEventParameters, - Dialog - >; -} - -declare module "sap/ui/webc/main/FileUploader" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `sap.ui.webc.main.FileUploader` opens a file explorer dialog and enables users to upload files. The - * component consists of input field, but you can provide an HTML element by your choice to trigger the - * file upload, by using the default slot. Furthermore, you can set the property "hideInput" to "true" to - * hide the input field. - * To get all selected files, you can simply use the read-only "files" property. To restrict the types - * of files the user can select, you can use the "accept" property. - * And, similar to all input based components, the FileUploader supports "valueState", "placeholder", "name", - * and "disabled" properties. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class FileUploader - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `FileUploader`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $FileUploaderSettings - ); - /** - * Constructor for a new `FileUploader`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $FileUploaderSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.FileUploader with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.FileUploader. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.FileUploader`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.FileUploader` itself. - * - * Event is fired when the value of the file path has been changed. **Note:** Keep in mind that because - * of the HTML input element of type file, the event is also fired in Chrome browser when the Cancel button - * of the uploads window is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: FileUploader$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.FileUploader` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.FileUploader`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.FileUploader` itself. - * - * Event is fired when the value of the file path has been changed. **Note:** Keep in mind that because - * of the HTML input element of type file, the event is also fired in Chrome browser when the Cancel button - * of the uploads window is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: FileUploader$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.FileUploader` itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.FileUploader`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: FileUploader$ChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: FileUploader$ChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccept accept}. - * - * Comma-separated list of file types that the component should accept. - * - * **Note:** Please make sure you are adding the `.` in front on the file type, e.g. `.png` in case you - * want to accept png's only. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accept` - */ - getAccept(): string; - /** - * Gets content of aggregation {@link #getContent content}. - * - * By default the component contains a single input field. With this slot you can pass any content that - * you wish to add. See the samples for more information. - * **Note:** If no content is provided in this slot, the component will only consist of an input field - * and will not be interactable using the keyboard. - * Also it is not recommended to use any non-interactable components, as it may lead to poor accessibility - * experience. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Returns the fileList of all selected files. - */ - getFiles(): void; - /** - * Gets current value of property {@link #getHideInput hideInput}. - * - * If set to "true", the input field of component will not be rendered. Only the default slot that is passed - * will be rendered. - * - * Default value is `false`. - * - * - * @returns Value of property `hideInput` - */ - getHideInput(): boolean; - /** - * Gets current value of property {@link #getMultiple multiple}. - * - * Allows multiple files to be chosen. - * - * Default value is `false`. - * - * - * @returns Value of property `multiple` - */ - getMultiple(): boolean; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the name/names of the file/files to upload. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccept accept}. - * - * Comma-separated list of file types that the component should accept. - * - * **Note:** Please make sure you are adding the `.` in front on the file type, e.g. `.png` in case you - * want to accept png's only. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccept( - /** - * New value for property `accept` - */ - sAccept?: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideInput hideInput}. - * - * If set to "true", the input field of component will not be rendered. Only the default slot that is passed - * will be rendered. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideInput( - /** - * New value for property `hideInput` - */ - bHideInput?: boolean - ): this; - /** - * Sets a new value for property {@link #getMultiple multiple}. - * - * Allows multiple files to be chosen. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMultiple( - /** - * New value for property `multiple` - */ - bMultiple?: boolean - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the name/names of the file/files to upload. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the FileUploader constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $FileUploaderSettings extends $WebComponentSettings { - /** - * Comma-separated list of file types that the component should accept. - * - * **Note:** Please make sure you are adding the `.` in front on the file type, e.g. `.png` in case you - * want to accept png's only. - */ - accept?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * If set to "true", the input field of component will not be rendered. Only the default slot that is passed - * will be rendered. - */ - hideInput?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Allows multiple files to be chosen. - */ - multiple?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines a short hint intended to aid the user with data entry when the component has no value. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Defines the name/names of the file/files to upload. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * By default the component contains a single input field. With this slot you can pass any content that - * you wish to add. See the samples for more information. - * **Note:** If no content is provided in this slot, the component will only consist of an input field - * and will not be interactable using the keyboard. - * Also it is not recommended to use any non-interactable components, as it may lead to poor accessibility - * experience. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Event is fired when the value of the file path has been changed. **Note:** Keep in mind that because - * of the HTML input element of type file, the event is also fired in Chrome browser when the Cancel button - * of the uploads window is pressed. - */ - change?: (oEvent: FileUploader$ChangeEvent) => void; - } - - /** - * Parameters of the FileUploader#change event. - */ - export interface FileUploader$ChangeEventParameters { - /** - * The current files. - */ - files?: FileList; - } - - /** - * Event object of the FileUploader#change event. - */ - export type FileUploader$ChangeEvent = Event< - FileUploader$ChangeEventParameters, - FileUploader - >; -} - -declare module "sap/ui/webc/main/GroupHeaderListItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IListItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.GroupHeaderListItem` is a special list item, used only to separate other list items - * into logical groups. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class GroupHeaderListItem - extends WebComponent - implements IListItem - { - __implements__sap_ui_webc_main_IListItem: boolean; - /** - * Constructor for a new `GroupHeaderListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $GroupHeaderListItemSettings - ); - /** - * Constructor for a new `GroupHeaderListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $GroupHeaderListItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.GroupHeaderListItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.GroupHeaderListItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the GroupHeaderListItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $GroupHeaderListItemSettings extends $WebComponentSettings { - /** - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/Icon" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IIcon, IconDesign } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import { CSSColor, CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Icon` component represents an SVG icon. There are two main scenarios how the `sap.ui.webc.main.Icon` - * component is used: as a purely decorative element, - * or as an interactive element that can be focused and clicked. - * - * Usage: - * - * 1. **Get familiar with the icons collections.** - * Before displaying an icon, you need to explore the icons collections to find and import the desired - * icon. - * Currently there are 3 icons collection, available as 3 npm packages: - * - * - * - * - {@link https://www.npmjs.com/package/@ui5/webcomponents-icons @ui5/webcomponents-icons} represents - * the "SAP-icons" collection and includes the following {@link demo:sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons icons}. - * - * - {@link https://www.npmjs.com/package/@ui5/webcomponents-icons-tnt @ui5/webcomponents-icons-tnt } - * represents the "tnt" collection and includes the following {@link demo:sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons-TNT icons}. - * - * - {@link https://www.npmjs.com/package/@ui5/webcomponents-icons-business-suite @ui5/webcomponents-icons-icons-business-suite } - * represents the "business-suite" collection and includes the following {@link https://ui5.sap.com/test-resources/sap/m/demokit/iconExplorer/webapp/index.html#/overview/BusinessSuiteInAppSymbols icons}. - * - * - * 2. **After exploring the icons collections, add one or more of the packages as dependencies to your project.** - * - * `npm i @ui5/webcomponents-icons` - * `npm i @ui5/webcomponents-icons-tnt` - * `npm i @ui5/webcomponents-icons-business-suite` - * - * - * - * **For Example**: - * - * - * 4. **Display the icon using the `sap.ui.webc.main.Icon` web component.** - * Set the icon collection ("SAP-icons", "tnt" or "business-suite" - "SAP-icons" is the default icon collection - * and can be skipped) - * and the icon name to the `name` property. - * - * - * - * `` - * `` - * `` - * - * - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Icon` exposes the following CSS Shadow Parts: - * - root - Used to style the outermost wrapper of the `sap.ui.webc.main.Icon` - * - * - * - * Keyboard Handling: - * - * - * - [SPACE, ENTER, RETURN] - Fires the `click` event if the `interactive` property is set to true. - * - [SHIFT] - If [SPACE] or [ENTER],[RETURN] is pressed, pressing [SHIFT] releases the ui5-icon without - * triggering the click event. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Icon extends WebComponent implements IIcon { - __implements__sap_ui_webc_main_IIcon: boolean; - /** - * Constructor for a new `Icon`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $IconSettings - ); - /** - * Constructor for a new `Icon`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $IconSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Icon with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Icon. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Icon`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Icon` itself. - * - * Fired when the user clicks the control - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Icon` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Icon`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Icon` itself. - * - * Fired when the user clicks the control - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Icon` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.Icon`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. If not provided a default text alternative will be set, - * if present. - * - * **Note:** Every icon should have a text alternative in order to calculate its accessible name. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAccessibleRole accessibleRole}. - * - * Defines the accessibility role of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleRole` - */ - getAccessibleRole(): string; - /** - * Gets current value of property {@link #getBackgroundColor backgroundColor}. - * - * Defines the background color of the control - * - * - * @returns Value of property `backgroundColor` - */ - getBackgroundColor(): CSSColor; - /** - * Gets current value of property {@link #getColor color}. - * - * Defines the color of the control - * - * - * @returns Value of property `color` - */ - getColor(): CSSColor; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component semantic design. - * - * - * - * **The available values are:** - * - * - * - `Contrast` - * - `Critical` - * - `Default` - * - `Information` - * - `Negative` - * - `Neutral` - * - `NonInteractive` - * - `Positive` - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): IconDesign; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getInteractive interactive}. - * - * Defines if the icon is interactive (focusable and pressable) - * - * Default value is `false`. - * - * - * @returns Value of property `interactive` - */ - getInteractive(): boolean; - /** - * Gets current value of property {@link #getName name}. - * - * Defines the unique identifier (icon name) of the component. - * - * - * To browse all available icons, see the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html SAP Icons}, - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons-TNT SAP Fiori Tools} and - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html SAP Business Suite} collections. - * - * - * Example: - * `name='add'`, `name='delete'`, `name='employee'`. - * - * - * - * **Note:** To use the SAP Fiori Tools icons, you need to set the `tnt` prefix in front of the icon's name. - * - * - * - * Example: - * `name='tnt/antenna'`, `name='tnt/actor'`, `name='tnt/api'`. - * - * - * - * **Note:** To use the SAP Business Suite icons, you need to set the `business-suite` prefix in front of - * the icon's name. - * - * - * Example: - * `name='business-suite/3d'`, `name='business-suite/1x2-grid-layout'`, `name='business-suite/4x4-grid-layout'`. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getShowTooltip showTooltip}. - * - * Defines whether the component should have a tooltip. - * - * **Note:** The tooltip text should be provided via the `accessible-name` property. - * - * Default value is `false`. - * - * - * @returns Value of property `showTooltip` - */ - getShowTooltip(): boolean; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. If not provided a default text alternative will be set, - * if present. - * - * **Note:** Every icon should have a text alternative in order to calculate its accessible name. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAccessibleRole accessibleRole}. - * - * Defines the accessibility role of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleRole( - /** - * New value for property `accessibleRole` - */ - sAccessibleRole?: string - ): this; - /** - * Sets a new value for property {@link #getBackgroundColor backgroundColor}. - * - * Defines the background color of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBackgroundColor( - /** - * New value for property `backgroundColor` - */ - sBackgroundColor: CSSColor - ): this; - /** - * Sets a new value for property {@link #getColor color}. - * - * Defines the color of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setColor( - /** - * New value for property `color` - */ - sColor: CSSColor - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component semantic design. - * - * - * - * **The available values are:** - * - * - * - `Contrast` - * - `Critical` - * - `Default` - * - `Information` - * - `Negative` - * - `Neutral` - * - `NonInteractive` - * - `Positive` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: IconDesign | keyof typeof IconDesign - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getInteractive interactive}. - * - * Defines if the icon is interactive (focusable and pressable) - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInteractive( - /** - * New value for property `interactive` - */ - bInteractive?: boolean - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Defines the unique identifier (icon name) of the component. - * - * - * To browse all available icons, see the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html SAP Icons}, - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons-TNT SAP Fiori Tools} and - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html SAP Business Suite} collections. - * - * - * Example: - * `name='add'`, `name='delete'`, `name='employee'`. - * - * - * - * **Note:** To use the SAP Fiori Tools icons, you need to set the `tnt` prefix in front of the icon's name. - * - * - * - * Example: - * `name='tnt/antenna'`, `name='tnt/actor'`, `name='tnt/api'`. - * - * - * - * **Note:** To use the SAP Business Suite icons, you need to set the `business-suite` prefix in front of - * the icon's name. - * - * - * Example: - * `name='business-suite/3d'`, `name='business-suite/1x2-grid-layout'`, `name='business-suite/4x4-grid-layout'`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getShowTooltip showTooltip}. - * - * Defines whether the component should have a tooltip. - * - * **Note:** The tooltip text should be provided via the `accessible-name` property. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowTooltip( - /** - * New value for property `showTooltip` - */ - bShowTooltip?: boolean - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Icon constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $IconSettings extends $WebComponentSettings { - /** - * Defines the text alternative of the component. If not provided a default text alternative will be set, - * if present. - * - * **Note:** Every icon should have a text alternative in order to calculate its accessible name. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the accessibility role of the component. - */ - accessibleRole?: string | PropertyBindingInfo; - - /** - * Defines the background color of the control - */ - backgroundColor?: CSSColor | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the color of the control - */ - color?: CSSColor | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the component semantic design. - * - * - * - * **The available values are:** - * - * - * - `Contrast` - * - `Critical` - * - `Default` - * - `Information` - * - `Negative` - * - `Neutral` - * - `NonInteractive` - * - `Positive` - */ - design?: - | (IconDesign | keyof typeof IconDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the icon is interactive (focusable and pressable) - */ - interactive?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the unique identifier (icon name) of the component. - * - * - * To browse all available icons, see the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html SAP Icons}, - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html#/overview/SAP-icons-TNT SAP Fiori Tools} and - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html SAP Business Suite} collections. - * - * - * Example: - * `name='add'`, `name='delete'`, `name='employee'`. - * - * - * - * **Note:** To use the SAP Fiori Tools icons, you need to set the `tnt` prefix in front of the icon's name. - * - * - * - * Example: - * `name='tnt/antenna'`, `name='tnt/actor'`, `name='tnt/api'`. - * - * - * - * **Note:** To use the SAP Business Suite icons, you need to set the `business-suite` prefix in front of - * the icon's name. - * - * - * Example: - * `name='business-suite/3d'`, `name='business-suite/1x2-grid-layout'`, `name='business-suite/4x4-grid-layout'`. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines whether the component should have a tooltip. - * - * **Note:** The tooltip text should be provided via the `accessible-name` property. - */ - showTooltip?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Fired when the user clicks the control - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the Icon#click event. - */ - export interface Icon$ClickEventParameters {} - - /** - * Event object of the Icon#click event. - */ - export type Icon$ClickEvent = Event; -} - -declare module "sap/ui/webc/main/Input" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - IInput, - IIcon, - IInputSuggestionItem, - InputType, - } from "sap/ui/webc/main/library"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Input` component allows the user to enter and edit text or numeric values in one - * line. - * Additionally, you can provide `suggestionItems`, that are displayed in a popover right under the input. - * - * - * The text field can be editable or read-only (`readonly` property), and it can be enabled or disabled - * (`disabled` property). To visualize semantic states, such as "error" or "warning", the `valueState` property - * is provided. When the user makes changes to the text, the change event is fired, which enables you to - * react on any text change. - * - * **Note:** If you are using the `sap.ui.webc.main.Input` as a single npm module, don't forget to import - * the `InputSuggestions` module from "@ui5/webcomponents/dist/features/InputSuggestions.js" to enable the - * suggestions functionality. - * - * Keyboard Handling: The `sap.ui.webc.main.Input` provides the following keyboard shortcuts: - * - * - * - * - [ESC] - Closes the suggestion list, if open. If closed or not enabled, cancels changes and reverts - * to the value which the Input field had when it got the focus. - * - [ENTER] or [RETURN] - If suggestion list is open takes over the current matching item and closes - * it. If value state or group header is focused, does nothing. - * - [DOWN] - Focuses the next matching item in the suggestion list. - * - [UP] - Focuses the previous matching item in the suggestion list. - * - [HOME] - If focus is in the text input, moves caret before the first character. If focus is in the - * list, highlights the first item and updates the input accordingly. - * - [END] - If focus is in the text input, moves caret after the last character. If focus is in the list, - * highlights the last item and updates the input accordingly. - * - [PAGEUP] - If focus is in the list, moves highlight up by page size (10 items by default). If focus - * is in the input, does nothing. - * - [PAGEDOWN] - If focus is in the list, moves highlight down by page size (10 items by default). If - * focus is in the input, does nothing. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Input - extends WebComponent - implements IInput, IFormContent - { - __implements__sap_ui_webc_main_IInput: boolean; - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `Input`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $InputSettings - ); - /** - * Constructor for a new `Input`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $InputSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Input with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Input. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some icon to the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addIcon( - /** - * The icon to add; if empty, nothing is inserted - */ - oIcon: IIcon - ): this; - /** - * Adds some suggestionItem to the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addSuggestionItem( - /** - * The suggestionItem to add; if empty, nothing is inserted - */ - oSuggestionItem: IInputSuggestionItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when the value of the component changes at each keystroke, and when a suggestion item has been - * selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when the value of the component changes at each keystroke, and when a suggestion item has been - * selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemPreview suggestionItemPreview } - * event of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when the user navigates to a suggestion item via the ARROW keys, as a preview, before the final - * selection. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemPreview( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Input$SuggestionItemPreviewEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemPreview suggestionItemPreview } - * event of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when the user navigates to a suggestion item via the ARROW keys, as a preview, before the final - * selection. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemPreview( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Input$SuggestionItemPreviewEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemSelect suggestionItemSelect} event - * of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when a suggestion item, that is displayed in the suggestion popup, is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemSelect( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Input$SuggestionItemSelectEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemSelect suggestionItemSelect} event - * of this `sap.ui.webc.main.Input`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Input` itself. - * - * Fired when a suggestion item, that is displayed in the suggestion popup, is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemSelect( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Input$SuggestionItemSelectEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Input` itself - */ - oListener?: object - ): this; - /** - * Destroys all the icon in the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyIcon(): this; - /** - * Destroys all the suggestionItems in the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySuggestionItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.Input`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.Input`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:suggestionItemPreview suggestionItemPreview } - * event of this `sap.ui.webc.main.Input`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSuggestionItemPreview( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Input$SuggestionItemPreviewEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:suggestionItemSelect suggestionItemSelect } - * event of this `sap.ui.webc.main.Input`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSuggestionItemSelect( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Input$SuggestionItemSelectEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:suggestionItemPreview suggestionItemPreview} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSuggestionItemPreview( - /** - * Parameters to pass along with the event - */ - mParameters?: Input$SuggestionItemPreviewEventParameters - ): this; - /** - * Fires event {@link #event:suggestionItemSelect suggestionItemSelect} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSuggestionItemSelect( - /** - * Parameters to pass along with the event - */ - mParameters?: Input$SuggestionItemSelectEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets content of aggregation {@link #getIcon icon}. - * - * Defines the icon to be displayed in the component. - */ - getIcon(): IIcon[]; - /** - * Gets current value of property {@link #getMaxlength maxlength}. - * - * Sets the maximum number of characters available in the input field. - * - * **Note:** This property is not compatible with the ui5-input type InputType.Number. If the ui5-input - * type is set to Number, the maxlength value is ignored. - * - * - * @returns Value of property `maxlength` - */ - getMaxlength(): int; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getNoTypeahead noTypeahead}. - * - * Defines whether the value will be autcompleted to match an item - * - * Default value is `false`. - * - * - * @returns Value of property `noTypeahead` - */ - getNoTypeahead(): boolean; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Returns the the suggestion item on preview. - */ - getPreviewItem(): void; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getShowClearIcon showClearIcon}. - * - * Defines whether the clear icon of the input will be shown. - * - * Default value is `false`. - * - * - * @returns Value of property `showClearIcon` - */ - getShowClearIcon(): boolean; - /** - * Gets current value of property {@link #getShowSuggestions showSuggestions}. - * - * Defines whether the component should show suggestions, if such are present. - * - * **Note:** You need to import the `InputSuggestions` module from `"@ui5/webcomponents/dist/features/InputSuggestions.js"` - * to enable this functionality. - * - * Default value is `false`. - * - * - * @returns Value of property `showSuggestions` - */ - getShowSuggestions(): boolean; - /** - * Gets content of aggregation {@link #getSuggestionItems suggestionItems}. - */ - getSuggestionItems(): IInputSuggestionItem[]; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the HTML type of the component. - * - * **Notes:** - * - The particular effect of this property differs depending on the browser and the current language - * settings, especially for type `Number`. - * - The property is mostly intended to be used with touch devices that use different soft keyboard layouts - * depending on the given input type. - * - * Default value is `Text`. - * - * - * @returns Value of property `type` - */ - getType(): InputType; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.IIcon` in the aggregation {@link #getIcon icon}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfIcon( - /** - * The icon whose index is looked for - */ - oIcon: IIcon - ): int; - /** - * Checks for the provided `sap.ui.webc.main.IInputSuggestionItem` in the aggregation {@link #getSuggestionItems suggestionItems}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfSuggestionItem( - /** - * The suggestionItem whose index is looked for - */ - oSuggestionItem: IInputSuggestionItem - ): int; - /** - * Inserts a icon into the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertIcon( - /** - * The icon to insert; if empty, nothing is inserted - */ - oIcon: IIcon, - /** - * The `0`-based index the icon should be inserted at; for a negative value of `iIndex`, the icon is inserted - * at position 0; for a value greater than the current size of the aggregation, the icon is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Inserts a suggestionItem into the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertSuggestionItem( - /** - * The suggestionItem to insert; if empty, nothing is inserted - */ - oSuggestionItem: IInputSuggestionItem, - /** - * The `0`-based index the suggestionItem should be inserted at; for a negative value of `iIndex`, the suggestionItem - * is inserted at position 0; for a value greater than the current size of the aggregation, the suggestionItem - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Manually opens the suggestions popover, assuming suggestions are enabled. Items must be preloaded for - * it to open. - */ - openPicker(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getIcon icon}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllIcon(): IIcon[]; - /** - * Removes all the controls from the aggregation {@link #getSuggestionItems suggestionItems}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllSuggestionItems(): IInputSuggestionItem[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a icon from the aggregation {@link #getIcon icon}. - * - * - * @returns The removed icon or `null` - */ - removeIcon( - /** - * The icon to remove or its index or id - */ - vIcon: int | string | IIcon - ): IIcon | null; - /** - * Removes a suggestionItem from the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns The removed suggestionItem or `null` - */ - removeSuggestionItem( - /** - * The suggestionItem to remove or its index or id - */ - vSuggestionItem: int | string | IInputSuggestionItem - ): IInputSuggestionItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getMaxlength maxlength}. - * - * Sets the maximum number of characters available in the input field. - * - * **Note:** This property is not compatible with the ui5-input type InputType.Number. If the ui5-input - * type is set to Number, the maxlength value is ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMaxlength( - /** - * New value for property `maxlength` - */ - iMaxlength: int - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getNoTypeahead noTypeahead}. - * - * Defines whether the value will be autcompleted to match an item - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoTypeahead( - /** - * New value for property `noTypeahead` - */ - bNoTypeahead?: boolean - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowClearIcon showClearIcon}. - * - * Defines whether the clear icon of the input will be shown. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowClearIcon( - /** - * New value for property `showClearIcon` - */ - bShowClearIcon?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowSuggestions showSuggestions}. - * - * Defines whether the component should show suggestions, if such are present. - * - * **Note:** You need to import the `InputSuggestions` module from `"@ui5/webcomponents/dist/features/InputSuggestions.js"` - * to enable this functionality. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowSuggestions( - /** - * New value for property `showSuggestions` - */ - bShowSuggestions?: boolean - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the HTML type of the component. - * - * **Notes:** - * - The particular effect of this property differs depending on the browser and the current language - * settings, especially for type `Number`. - * - The property is mostly intended to be used with touch devices that use different soft keyboard layouts - * depending on the given input type. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Text`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: InputType | keyof typeof InputType - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Input constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $InputSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Sets the maximum number of characters available in the input field. - * - * **Note:** This property is not compatible with the ui5-input type InputType.Number. If the ui5-input - * type is set to Number, the maxlength value is ignored. - */ - maxlength?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines whether the value will be autcompleted to match an item - */ - noTypeahead?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a short hint intended to aid the user with data entry when the component has no value. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the clear icon of the input will be shown. - */ - showClearIcon?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component should show suggestions, if such are present. - * - * **Note:** You need to import the `InputSuggestions` module from `"@ui5/webcomponents/dist/features/InputSuggestions.js"` - * to enable this functionality. - */ - showSuggestions?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the HTML type of the component. - * - * **Notes:** - * - The particular effect of this property differs depending on the browser and the current language - * settings, especially for type `Number`. - * - The property is mostly intended to be used with touch devices that use different soft keyboard layouts - * depending on the given input type. - */ - type?: - | (InputType | keyof typeof InputType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon to be displayed in the component. - */ - icon?: IIcon[] | IIcon | AggregationBindingInfo | `{${string}}`; - - suggestionItems?: - | IInputSuggestionItem[] - | IInputSuggestionItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter or on focusout. - */ - change?: (oEvent: Event) => void; - - /** - * Fired when the value of the component changes at each keystroke, and when a suggestion item has been - * selected. - */ - input?: (oEvent: Event) => void; - - /** - * Fired when the user navigates to a suggestion item via the ARROW keys, as a preview, before the final - * selection. - */ - suggestionItemPreview?: (oEvent: Input$SuggestionItemPreviewEvent) => void; - - /** - * Fired when a suggestion item, that is displayed in the suggestion popup, is selected. - */ - suggestionItemSelect?: (oEvent: Input$SuggestionItemSelectEvent) => void; - } - - /** - * Parameters of the Input#change event. - */ - export interface Input$ChangeEventParameters {} - - /** - * Event object of the Input#change event. - */ - export type Input$ChangeEvent = Event; - - /** - * Parameters of the Input#input event. - */ - export interface Input$InputEventParameters {} - - /** - * Event object of the Input#input event. - */ - export type Input$InputEvent = Event; - - /** - * Parameters of the Input#suggestionItemPreview event. - */ - export interface Input$SuggestionItemPreviewEventParameters { - /** - * The previewed suggestion item. - */ - item?: HTMLElement; - - /** - * The DOM ref of the suggestion item. - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the Input#suggestionItemPreview event. - */ - export type Input$SuggestionItemPreviewEvent = Event< - Input$SuggestionItemPreviewEventParameters, - Input - >; - - /** - * Parameters of the Input#suggestionItemSelect event. - */ - export interface Input$SuggestionItemSelectEventParameters { - /** - * The selected item. - */ - item?: HTMLElement; - } - - /** - * Event object of the Input#suggestionItemSelect event. - */ - export type Input$SuggestionItemSelectEvent = Event< - Input$SuggestionItemSelectEventParameters, - Input - >; -} - -declare module "sap/ui/webc/main/Label" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { Label as Label1, ID, CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { WrappingType } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Label` is a component used to represent a label for elements like input, textarea, - * select. - * - * The `for` property of the `sap.ui.webc.main.Label` must be the same as the id attribute of the related - * input element. - * - * Screen readers read out the label, when the user focuses the labelled control. - * - * The `sap.ui.webc.main.Label` appearance can be influenced by properties, such as `required` and `wrappingType`. - * The appearance of the Label can be configured in a limited way by using the design property. For a broader - * choice of designs, you can use custom styles. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Label extends WebComponent implements Label1 { - __implements__sap_ui_core_Label: boolean; - /** - * Constructor for a new `Label`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $LabelSettings - ); - /** - * Constructor for a new `Label`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $LabelSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Label with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Label. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * ID of the element which is the current target of the association {@link #getLabelFor labelFor}, or `null`. - */ - getLabelFor(): ID | null; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether an asterisk character is added to the component text. - * - * **Note:** Usually indicates that user input (bound with the `for` property) is required. In that case - * the required property of the corresponding input should also be set. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getShowColon showColon}. - * - * Defines whether colon is added to the component text. - * - * **Note:** Usually used in forms. - * - * Default value is `false`. - * - * - * @returns Value of property `showColon` - */ - getShowColon(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Gets current value of property {@link #getWrappingType wrappingType}. - * - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * Default value is `None`. - * - * - * @returns Value of property `wrappingType` - */ - getWrappingType(): WrappingType; - /** - * Sets the associated {@link #getLabelFor labelFor}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLabelFor( - /** - * ID of an element which becomes the new target of this labelFor association; alternatively, an element - * instance may be given - */ - oLabelFor: ID | Control - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether an asterisk character is added to the component text. - * - * **Note:** Usually indicates that user input (bound with the `for` property) is required. In that case - * the required property of the corresponding input should also be set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowColon showColon}. - * - * Defines whether colon is added to the component text. - * - * **Note:** Usually used in forms. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowColon( - /** - * New value for property `showColon` - */ - bShowColon?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Sets a new value for property {@link #getWrappingType wrappingType}. - * - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWrappingType( - /** - * New value for property `wrappingType` - */ - sWrappingType?: WrappingType | keyof typeof WrappingType - ): this; - } - /** - * Describes the settings that can be provided to the Label constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $LabelSettings extends $WebComponentSettings { - /** - * Defines whether an asterisk character is added to the component text. - * - * **Note:** Usually indicates that user input (bound with the `for` property) is required. In that case - * the required property of the corresponding input should also be set. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether colon is added to the component text. - * - * **Note:** Usually used in forms. - */ - showColon?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - */ - wrappingType?: - | (WrappingType | keyof typeof WrappingType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Association to the labelled control. - * - * - * By default, the label sets the for attribute to the ID of the labelled control. This can be changed by - * implementing the function getIdForLabel on the labelled control. - */ - labelFor?: Control | string; - } -} - -declare module "sap/ui/webc/main/Link" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { LinkDesign, WrappingType } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The `sap.ui.webc.main.Link` is a hyperlink component that is used to navigate to other apps - * and web pages, or to trigger actions. It is a clickable text element, visualized in such a way that it - * stands out from the standard text. On hover, it changes its style to an underlined text to provide additional - * feedback to the user. - * - * Usage: - * - * You can set the `sap.ui.webc.main.Link` to be enabled or disabled. - * - * To create a visual hierarchy in large lists of links, you can set the less important links as `Subtle` - * or the more important ones as `Emphasized`, by using the `design` property. - * - * If the `href` property is set, the link behaves as the HTML anchor tag (``) and - * opens the specified URL in the given target frame (`target` property). To specify where the linked content - * is opened, you can use the `target` property. - * - * Responsive behavior: - * - * If there is not enough space, the text of the `sap.ui.webc.main.Link` becomes truncated. If the `wrappingType` - * property is set to `"Normal"`, the text is displayed on several lines instead of being truncated. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Link extends WebComponent { - /** - * Constructor for a new `Link`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $LinkSettings - ); - /** - * Constructor for a new `Link`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $LinkSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Link with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Link. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Link`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Link` itself. - * - * Fired when the component is triggered either with a mouse/tap or by using the Enter key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Link$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Link` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.Link`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Link` itself. - * - * Fired when the component is triggered either with a mouse/tap or by using the Enter key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Link$ClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Link` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.Link`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Link$ClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: Link$ClickEventParameters - ): boolean; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the anchor element, or another grouping element it controls, is currently - * expanded or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the anchor element. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAccessibleRole accessibleRole}. - * - * Defines the ARIA role of the component. - * - * **Note:** Use the "button" role in cases when navigation is not expected to occur and the href property - * is not defined. - * - * Default value is `"link"`. - * - * - * @returns Value of property `accessibleRole` - */ - getAccessibleRole(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component design. - * - * **Note:** Avaialble options are `Default`, `Subtle`, and `Emphasized`. - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): LinkDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getHref href}. - * - * Defines the component href. - * - * **Note:** Standard hyperlink behavior is supported. - * - * Default value is `empty string`. - * - * - * @returns Value of property `href` - */ - getHref(): string; - /** - * Gets current value of property {@link #getTarget target}. - * - * Defines the component target. - * - * **Notes:** - * - * - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * **This property must only be used when the `href` property is set.** - * - * Default value is `empty string`. - * - * - * @returns Value of property `target` - */ - getTarget(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWrappingType wrappingType}. - * - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * Default value is `None`. - * - * - * @returns Value of property `wrappingType` - */ - getWrappingType(): WrappingType; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the anchor element, or another grouping element it controls, is currently - * expanded or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the anchor element. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAccessibleRole accessibleRole}. - * - * Defines the ARIA role of the component. - * - * **Note:** Use the "button" role in cases when navigation is not expected to occur and the href property - * is not defined. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `"link"`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleRole( - /** - * New value for property `accessibleRole` - */ - sAccessibleRole?: string - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component design. - * - * **Note:** Avaialble options are `Default`, `Subtle`, and `Emphasized`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: LinkDesign | keyof typeof LinkDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getHref href}. - * - * Defines the component href. - * - * **Note:** Standard hyperlink behavior is supported. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHref( - /** - * New value for property `href` - */ - sHref?: string - ): this; - /** - * Sets a new value for property {@link #getTarget target}. - * - * Defines the component target. - * - * **Notes:** - * - * - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * **This property must only be used when the `href` property is set.** - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTarget( - /** - * New value for property `target` - */ - sTarget?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWrappingType wrappingType}. - * - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWrappingType( - /** - * New value for property `wrappingType` - */ - sWrappingType?: WrappingType | keyof typeof WrappingType - ): this; - } - /** - * Describes the settings that can be provided to the Link constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $LinkSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the anchor element, or another grouping element it controls, is currently - * expanded or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the anchor element. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the ARIA role of the component. - * - * **Note:** Use the "button" role in cases when navigation is not expected to occur and the href property - * is not defined. - */ - accessibleRole?: string | PropertyBindingInfo; - - /** - * Defines the component design. - * - * **Note:** Avaialble options are `Default`, `Subtle`, and `Emphasized`. - */ - design?: - | (LinkDesign | keyof typeof LinkDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the component href. - * - * **Note:** Standard hyperlink behavior is supported. - */ - href?: string | PropertyBindingInfo; - - /** - * Defines the component target. - * - * **Notes:** - * - * - * - `_self` - * - `_top` - * - `_blank` - * - `_parent` - * - `_search` - * - * **This property must only be used when the `href` property is set.** - */ - target?: string | PropertyBindingInfo; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - */ - wrappingType?: - | (WrappingType | keyof typeof WrappingType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component is triggered either with a mouse/tap or by using the Enter key. - */ - click?: (oEvent: Link$ClickEvent) => void; - } - - /** - * Parameters of the Link#click event. - */ - export interface Link$ClickEventParameters { - /** - * Returns whether the "ALT" key was pressed when the event was triggered. - */ - altKey?: boolean; - - /** - * Returns whether the "CTRL" key was pressed when the event was triggered. - */ - ctrlKey?: boolean; - - /** - * Returns whether the "META" key was pressed when the event was triggered. - */ - metaKey?: boolean; - - /** - * Returns whether the "SHIFT" key was pressed when the event was triggered. - */ - shiftKey?: boolean; - } - - /** - * Event object of the Link#click event. - */ - export type Link$ClickEvent = Event; -} - -declare module "sap/ui/webc/main/List" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { - IListItem, - ListGrowingMode, - ListMode, - ListSeparators, - } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.List` component allows displaying a list of items, advanced keyboard handling support - * for navigating between items, and predefined modes to improve the development efficiency. - * - * The `sap.ui.webc.main.List` is a container for the available list items: - * - `sap.ui.webc.main.StandardListItem` - * - `sap.ui.webc.main.CustomListItem` - * - `sap.ui.webc.main.GroupHeaderListItem` - * - * To benefit from the built-in selection mechanism, you can use the available selection modes, such as - * `SingleSelect`, `MultiSelect` and `Delete`. - * - * Additionally, the `sap.ui.webc.main.List` provides header, footer, and customization for the list item - * separators. - * - * - * - * Keyboard Handling: - * - * Basic Navigation: The `sap.ui.webc.main.List` provides advanced keyboard handling. When a list is focused - * the user can use the following keyboard shortcuts in order to perform a navigation: - * - * - * - * - [UP/DOWN] - Navigates up and down the items - * - [HOME] - Navigates to first item - * - [END] - Navigates to the last item - * - * The user can use the following keyboard shortcuts to perform actions (such as select, delete), when the - * `mode` property is in use: - * - [SPACE] - Select an item (if `type` is 'Active') when `mode` is selection - * - [DELETE] - Delete an item if `mode` property is `Delete` - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class List extends WebComponent { - /** - * Constructor for a new `List`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ListSettings - ); - /** - * Constructor for a new `List`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ListSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.List with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.List. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IListItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when an item is activated, unless the item's `type` property is set to `Inactive`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when an item is activated, unless the item's `type` property is set to `Inactive`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClose itemClose} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the `Close` button of any item is clicked - * - * **Note:** This event is only applicable to list items that can be closed (such as notification list - * items), not to be confused with `item-delete`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClose itemClose} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the `Close` button of any item is clicked - * - * **Note:** This event is only applicable to list items that can be closed (such as notification list - * items), not to be confused with `item-delete`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the Delete button of any item is pressed. - * - * **Note:** A Delete button is displayed on each item, when the component `mode` property is set to `Delete`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemDelete( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the Delete button of any item is pressed. - * - * **Note:** A Delete button is displayed on each item, when the component `mode` property is set to `Delete`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemDelete( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemToggle itemToggle} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the `Toggle` button of any item is clicked. - * - * **Note:** This event is only applicable to list items that can be toggled (such as notification group - * list items). - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemToggle( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemToggleEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemToggle itemToggle} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the `Toggle` button of any item is clicked. - * - * **Note:** This event is only applicable to list items that can be toggled (such as notification group - * list items). - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemToggle( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$ItemToggleEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:loadMore loadMore} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the user scrolls to the bottom of the list. - * - * **Note:** The event is fired when the `growing='Scroll'` property is enabled. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLoadMore( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:loadMore loadMore} event of this `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when the user scrolls to the bottom of the list. - * - * **Note:** The event is fired when the `growing='Scroll'` property is enabled. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLoadMore( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd` - * and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.List`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.List` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd` - * and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: List$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.List` itself - */ - oListener?: object - ): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.List`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: List$ItemClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemClose itemClose} event of this `sap.ui.webc.main.List`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: List$ItemCloseEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.main.List`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemDelete( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: List$ItemDeleteEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemToggle itemToggle} event of this `sap.ui.webc.main.List`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemToggle( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: List$ItemToggleEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:loadMore loadMore} event of this `sap.ui.webc.main.List`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachLoadMore( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.main.List`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: List$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:itemClick itemClick} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireItemClick( - /** - * Parameters to pass along with the event - */ - mParameters?: List$ItemClickEventParameters - ): boolean; - /** - * Fires event {@link #event:itemClose itemClose} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemClose( - /** - * Parameters to pass along with the event - */ - mParameters?: List$ItemCloseEventParameters - ): this; - /** - * Fires event {@link #event:itemDelete itemDelete} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemDelete( - /** - * Parameters to pass along with the event - */ - mParameters?: List$ItemDeleteEventParameters - ): this; - /** - * Fires event {@link #event:itemToggle itemToggle} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemToggle( - /** - * Parameters to pass along with the event - */ - mParameters?: List$ItemToggleEventParameters - ): this; - /** - * Fires event {@link #event:loadMore loadMore} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireLoadMore( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: List$SelectionChangeEventParameters - ): boolean; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAccessibleRole accessibleRole}. - * - * Defines the accessible role of the component. - * - * - * - * Default value is `"list"`. - * - * - * @returns Value of property `accessibleRole` - */ - getAccessibleRole(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getBusy busy}. - * - * Defines if the component would display a loading indicator over the list. - * - * Default value is `false`. - * - * - * @returns Value of property `busy` - */ - getBusy(): boolean; - /** - * Gets current value of property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * Default value is `1000`. - * - * - * @returns Value of property `busyDelay` - */ - getBusyDelay(): int; - /** - * Gets current value of property {@link #getFooterText footerText}. - * - * Defines the footer text. - * - * Default value is `empty string`. - * - * - * @returns Value of property `footerText` - */ - getFooterText(): string; - /** - * Gets current value of property {@link #getGrowing growing}. - * - * Defines whether the component will have growing capability either by pressing a `More` button, or via - * user scroll. In both cases `load-more` event is fired. - * - * - * - * Available options: - * - * `Button` - Shows a `More` button at the bottom of the list, pressing of which triggers the `load-more` - * event. - * `Scroll` - The `load-more` event is triggered when the user scrolls to the bottom of the list; - * `None` (default) - The growing is off. - * - * - * - * **Restrictions:** `growing="Scroll"` is not supported for Internet Explorer, on IE the component will - * fallback to `growing="Button"`. - * - * Default value is `None`. - * - * - * @returns Value of property `growing` - */ - getGrowing(): ListGrowingMode; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the component header. - * - * **Note:** When `header` is set, the `headerText` property is ignored. - */ - getHeader(): Control[]; - /** - * Gets current value of property {@link #getHeaderText headerText}. - * - * Defines the component header text. - * - * **Note:** If `header` is set this property is ignored. - * - * Default value is `empty string`. - * - * - * @returns Value of property `headerText` - */ - getHeaderText(): string; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getIndent indent}. - * - * Determines whether the component is indented. - * - * Default value is `false`. - * - * - * @returns Value of property `indent` - */ - getIndent(): boolean; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the component. - * - * **Note:** Use `sap.ui.webc.main.StandardListItem`, `sap.ui.webc.main.CustomListItem`, and `sap.ui.webc.main.GroupHeaderListItem` - * for the intended design. - */ - getItems(): IListItem[]; - /** - * Gets current value of property {@link #getMode mode}. - * - * Defines the mode of the component. - * - * **Note:** Available options are `None`, `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd`, `MultiSelect`, - * and `Delete`. - * - * Default value is `None`. - * - * - * @returns Value of property `mode` - */ - getMode(): ListMode; - /** - * Gets current value of property {@link #getNoDataText noDataText}. - * - * Defines the text that is displayed when the component contains no items. - * - * Default value is `empty string`. - * - * - * @returns Value of property `noDataText` - */ - getNoDataText(): string; - /** - * Gets current value of property {@link #getSeparators separators}. - * - * Defines the item separator style that is used. - * - * **Notes:** - * - Avalaible options are `All`, `Inner`, and `None`. - * - When set to `None`, none of the items are separated by horizontal lines. - * - When set to `Inner`, the first item doesn't have a top separator and the last item doesn't have a - * bottom separator. - * - * Default value is `All`. - * - * - * @returns Value of property `separators` - */ - getSeparators(): ListSeparators; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.main.IListItem` in the aggregation {@link #getItems items}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IListItem - ): int; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IListItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IListItem[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IListItem - ): IListItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAccessibleRole accessibleRole}. - * - * Defines the accessible role of the component. - * - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `"list"`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleRole( - /** - * New value for property `accessibleRole` - */ - sAccessibleRole?: string - ): this; - /** - * Sets a new value for property {@link #getBusy busy}. - * - * Defines if the component would display a loading indicator over the list. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusy( - /** - * New value for property `busy` - */ - bBusy?: boolean - ): this; - /** - * Sets a new value for property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusyDelay( - /** - * New value for property `busyDelay` - */ - iBusyDelay?: int - ): this; - /** - * Sets a new value for property {@link #getFooterText footerText}. - * - * Defines the footer text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFooterText( - /** - * New value for property `footerText` - */ - sFooterText?: string - ): this; - /** - * Sets a new value for property {@link #getGrowing growing}. - * - * Defines whether the component will have growing capability either by pressing a `More` button, or via - * user scroll. In both cases `load-more` event is fired. - * - * - * - * Available options: - * - * `Button` - Shows a `More` button at the bottom of the list, pressing of which triggers the `load-more` - * event. - * `Scroll` - The `load-more` event is triggered when the user scrolls to the bottom of the list; - * `None` (default) - The growing is off. - * - * - * - * **Restrictions:** `growing="Scroll"` is not supported for Internet Explorer, on IE the component will - * fallback to `growing="Button"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setGrowing( - /** - * New value for property `growing` - */ - sGrowing?: ListGrowingMode | keyof typeof ListGrowingMode - ): this; - /** - * Sets a new value for property {@link #getHeaderText headerText}. - * - * Defines the component header text. - * - * **Note:** If `header` is set this property is ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderText( - /** - * New value for property `headerText` - */ - sHeaderText?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getIndent indent}. - * - * Determines whether the component is indented. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIndent( - /** - * New value for property `indent` - */ - bIndent?: boolean - ): this; - /** - * Sets a new value for property {@link #getMode mode}. - * - * Defines the mode of the component. - * - * **Note:** Available options are `None`, `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd`, `MultiSelect`, - * and `Delete`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMode( - /** - * New value for property `mode` - */ - sMode?: ListMode | keyof typeof ListMode - ): this; - /** - * Sets a new value for property {@link #getNoDataText noDataText}. - * - * Defines the text that is displayed when the component contains no items. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoDataText( - /** - * New value for property `noDataText` - */ - sNoDataText?: string - ): this; - /** - * Sets a new value for property {@link #getSeparators separators}. - * - * Defines the item separator style that is used. - * - * **Notes:** - * - Avalaible options are `All`, `Inner`, and `None`. - * - When set to `None`, none of the items are separated by horizontal lines. - * - When set to `Inner`, the first item doesn't have a top separator and the last item doesn't have a - * bottom separator. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `All`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSeparators( - /** - * New value for property `separators` - */ - sSeparators?: ListSeparators | keyof typeof ListSeparators - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the List constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ListSettings extends $WebComponentSettings { - /** - * Defines the accessible name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the accessible role of the component. - */ - accessibleRole?: string | PropertyBindingInfo; - - /** - * Defines if the component would display a loading indicator over the list. - */ - busy?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - */ - busyDelay?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the footer text. - */ - footerText?: string | PropertyBindingInfo; - - /** - * Defines whether the component will have growing capability either by pressing a `More` button, or via - * user scroll. In both cases `load-more` event is fired. - * - * - * - * Available options: - * - * `Button` - Shows a `More` button at the bottom of the list, pressing of which triggers the `load-more` - * event. - * `Scroll` - The `load-more` event is triggered when the user scrolls to the bottom of the list; - * `None` (default) - The growing is off. - * - * - * - * **Restrictions:** `growing="Scroll"` is not supported for Internet Explorer, on IE the component will - * fallback to `growing="Button"`. - */ - growing?: - | (ListGrowingMode | keyof typeof ListGrowingMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the component header text. - * - * **Note:** If `header` is set this property is ignored. - */ - headerText?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Determines whether the component is indented. - */ - indent?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the mode of the component. - * - * **Note:** Available options are `None`, `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd`, `MultiSelect`, - * and `Delete`. - */ - mode?: - | (ListMode | keyof typeof ListMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the text that is displayed when the component contains no items. - */ - noDataText?: string | PropertyBindingInfo; - - /** - * Defines the item separator style that is used. - * - * **Notes:** - * - Avalaible options are `All`, `Inner`, and `None`. - * - When set to `None`, none of the items are separated by horizontal lines. - * - When set to `Inner`, the first item doesn't have a top separator and the last item doesn't have a - * bottom separator. - */ - separators?: - | (ListSeparators | keyof typeof ListSeparators) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the component header. - * - * **Note:** When `header` is set, the `headerText` property is ignored. - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the items of the component. - * - * **Note:** Use `sap.ui.webc.main.StandardListItem`, `sap.ui.webc.main.CustomListItem`, and `sap.ui.webc.main.GroupHeaderListItem` - * for the intended design. - */ - items?: IListItem[] | IListItem | AggregationBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when an item is activated, unless the item's `type` property is set to `Inactive`. - */ - itemClick?: (oEvent: List$ItemClickEvent) => void; - - /** - * Fired when the `Close` button of any item is clicked - * - * **Note:** This event is only applicable to list items that can be closed (such as notification list - * items), not to be confused with `item-delete`. - */ - itemClose?: (oEvent: List$ItemCloseEvent) => void; - - /** - * Fired when the Delete button of any item is pressed. - * - * **Note:** A Delete button is displayed on each item, when the component `mode` property is set to `Delete`. - */ - itemDelete?: (oEvent: List$ItemDeleteEvent) => void; - - /** - * Fired when the `Toggle` button of any item is clicked. - * - * **Note:** This event is only applicable to list items that can be toggled (such as notification group - * list items). - */ - itemToggle?: (oEvent: List$ItemToggleEvent) => void; - - /** - * Fired when the user scrolls to the bottom of the list. - * - * **Note:** The event is fired when the `growing='Scroll'` property is enabled. - */ - loadMore?: (oEvent: Event) => void; - - /** - * Fired when selection is changed by user interaction in `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd` - * and `MultiSelect` modes. - */ - selectionChange?: (oEvent: List$SelectionChangeEvent) => void; - } - - /** - * Parameters of the List#itemClick event. - */ - export interface List$ItemClickEventParameters { - /** - * The clicked item. - */ - item?: HTMLElement; - } - - /** - * Event object of the List#itemClick event. - */ - export type List$ItemClickEvent = Event; - - /** - * Parameters of the List#itemClose event. - */ - export interface List$ItemCloseEventParameters { - /** - * the item about to be closed. - */ - item?: HTMLElement; - } - - /** - * Event object of the List#itemClose event. - */ - export type List$ItemCloseEvent = Event; - - /** - * Parameters of the List#itemDelete event. - */ - export interface List$ItemDeleteEventParameters { - /** - * the deleted item. - */ - item?: HTMLElement; - } - - /** - * Event object of the List#itemDelete event. - */ - export type List$ItemDeleteEvent = Event< - List$ItemDeleteEventParameters, - List - >; - - /** - * Parameters of the List#itemToggle event. - */ - export interface List$ItemToggleEventParameters { - /** - * the toggled item. - */ - item?: HTMLElement; - } - - /** - * Event object of the List#itemToggle event. - */ - export type List$ItemToggleEvent = Event< - List$ItemToggleEventParameters, - List - >; - - /** - * Parameters of the List#loadMore event. - */ - export interface List$LoadMoreEventParameters {} - - /** - * Event object of the List#loadMore event. - */ - export type List$LoadMoreEvent = Event; - - /** - * Parameters of the List#selectionChange event. - */ - export interface List$SelectionChangeEventParameters { - /** - * An array of the selected items. - */ - selectedItems?: any[]; - - /** - * An array of the previously selected items. - */ - previouslySelectedItems?: any[]; - } - - /** - * Event object of the List#selectionChange event. - */ - export type List$SelectionChangeEvent = Event< - List$SelectionChangeEventParameters, - List - >; -} - -declare module "sap/ui/webc/main/Menu" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IMenuItem } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { ID } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * `sap.ui.webc.main.Menu` component represents a hierarchical menu structure. - * - * Usage: - * - * `sap.ui.webc.main.Menu` contains `sap.ui.webc.main.MenuItem` components. An arbitrary hierarchy structure - * can be represented by recursively nesting menu items. - * - * Keyboard Handling: - * - * The `sap.ui.webc.main.Menu` provides advanced keyboard handling. The user can use the following keyboard - * shortcuts in order to navigate trough the tree: - * - `Arrow Up` / `Arrow Down` - Navigates up and down the menu items that are currently visible. - * - `Arrow Right`, `Space` or `Enter` - Opens a sub-menu if there are menu items nested in the currently - * clicked menu item. - * - `Arrow Left` or `Escape` - Closes the currently opened sub-menu. Note: if the text ditrection - * is set to Right-to-left (RTL), `Arrow Right` and `Arrow Left` functionality is swapped. - * - * - * @since 1.102.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.102.0. This control is experimental and its API might change significantly. - */ - export default class Menu extends WebComponent { - /** - * Constructor for a new `Menu`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MenuSettings - ); - /** - * Constructor for a new `Menu`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MenuSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Menu with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Menu. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IMenuItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired after the menu is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired after the menu is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired after the menu is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired after the menu is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired before the menu is closed. This event can be cancelled, which will prevent the menu from closing. - * **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Menu$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired before the menu is closed. This event can be cancelled, which will prevent the menu from closing. - * **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Menu$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired before the menu is opened. This event can be cancelled, which will prevent the menu from opening. - * **This event does not bubble.** **Note:** Since 1.14.0 the event is also fired before a sub-menu opens. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Menu$BeforeOpenEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired before the menu is opened. This event can be cancelled, which will prevent the menu from opening. - * **This event does not bubble.** **Note:** Since 1.14.0 the event is also fired before a sub-menu opens. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Menu$BeforeOpenEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired when an item is being clicked. **Note:** Since 1.17.0 the event is preventable, allowing the menu - * to remain open after an item is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Menu$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Menu`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Menu` itself. - * - * Fired when an item is being clicked. **Note:** Since 1.17.0 the event is preventable, allowing the menu - * to remain open after an item is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Menu$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Menu` itself - */ - oListener?: object - ): this; - /** - * Closes the Menu. - */ - close(): void; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Menu`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Menu`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Menu`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Menu$BeforeCloseEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Menu`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Menu$BeforeOpenEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Menu`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Menu$ItemClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:afterClose afterClose} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterClose( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:afterOpen afterOpen} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:beforeClose beforeClose} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeClose( - /** - * Parameters to pass along with the event - */ - mParameters?: Menu$BeforeCloseEventParameters - ): boolean; - /** - * Fires event {@link #event:beforeOpen beforeOpen} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: Menu$BeforeOpenEventParameters - ): boolean; - /** - * Fires event {@link #event:itemClick itemClick} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireItemClick( - /** - * Parameters to pass along with the event - */ - mParameters?: Menu$ItemClickEventParameters - ): boolean; - /** - * Gets current value of property {@link #getBusy busy}. - * - * Defines if a loading indicator would be displayed inside the corresponding ui5-menu popover. - * - * Default value is `false`. - * - * - * @returns Value of property `busy` - */ - getBusy(): boolean; - /** - * Gets current value of property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover.. - * - * Default value is `1000`. - * - * - * @returns Value of property `busyDelay` - */ - getBusyDelay(): int; - /** - * Gets current value of property {@link #getHeaderText headerText}. - * - * Defines the header text of the menu (displayed on mobile). - * - * Default value is `empty string`. - * - * - * @returns Value of property `headerText` - */ - getHeaderText(): string; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of this component. - * - * **Note:** Use `sap.ui.webc.main.MenuItem` for the intended design. - */ - getItems(): IMenuItem[]; - /** - * Gets current value of property {@link #getOpen open}. - * - * Indicates if the menu is open - * - * Default value is `false`. - * - * - * @returns Value of property `open` - */ - getOpen(): boolean; - /** - * ID of the element which is the current target of the association {@link #getOpener opener}, or `null`. - */ - getOpener(): ID | null; - /** - * Checks for the provided `sap.ui.webc.main.IMenuItem` in the aggregation {@link #getItems items}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IMenuItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IMenuItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IMenuItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IMenuItem - ): IMenuItem | null; - /** - * Sets a new value for property {@link #getBusy busy}. - * - * Defines if a loading indicator would be displayed inside the corresponding ui5-menu popover. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusy( - /** - * New value for property `busy` - */ - bBusy?: boolean - ): this; - /** - * Sets a new value for property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover.. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusyDelay( - /** - * New value for property `busyDelay` - */ - iBusyDelay?: int - ): this; - /** - * Sets a new value for property {@link #getHeaderText headerText}. - * - * Defines the header text of the menu (displayed on mobile). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderText( - /** - * New value for property `headerText` - */ - sHeaderText?: string - ): this; - /** - * Sets a new value for property {@link #getOpen open}. - * - * Indicates if the menu is open - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOpen( - /** - * New value for property `open` - */ - bOpen?: boolean - ): this; - /** - * Sets the associated {@link #getOpener opener}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOpener( - /** - * ID of an element which becomes the new target of this opener association; alternatively, an element instance - * may be given - */ - oOpener: ID | Control - ): this; - /** - * Shows the Menu near the opener element. - */ - showAt( - /** - * the element that the popover is shown at - */ - opener: HTMLElement - ): void; - } - /** - * Describes the settings that can be provided to the Menu constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.102.0. This control is experimental and its API might change significantly. - */ - export interface $MenuSettings extends $WebComponentSettings { - /** - * Defines if a loading indicator would be displayed inside the corresponding ui5-menu popover. - */ - busy?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover.. - */ - busyDelay?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the header text of the menu (displayed on mobile). - */ - headerText?: string | PropertyBindingInfo; - - /** - * Indicates if the menu is open - */ - open?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the items of this component. - * - * **Note:** Use `sap.ui.webc.main.MenuItem` for the intended design. - */ - items?: IMenuItem[] | IMenuItem | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the ID or DOM Reference of the element that the menu is shown at - */ - opener?: Control | string; - - /** - * Fired after the menu is closed. **This event does not bubble.** - */ - afterClose?: (oEvent: Event) => void; - - /** - * Fired after the menu is opened. **This event does not bubble.** - */ - afterOpen?: (oEvent: Event) => void; - - /** - * Fired before the menu is closed. This event can be cancelled, which will prevent the menu from closing. - * **This event does not bubble.** - */ - beforeClose?: (oEvent: Menu$BeforeCloseEvent) => void; - - /** - * Fired before the menu is opened. This event can be cancelled, which will prevent the menu from opening. - * **This event does not bubble.** **Note:** Since 1.14.0 the event is also fired before a sub-menu opens. - */ - beforeOpen?: (oEvent: Menu$BeforeOpenEvent) => void; - - /** - * Fired when an item is being clicked. **Note:** Since 1.17.0 the event is preventable, allowing the menu - * to remain open after an item is pressed. - */ - itemClick?: (oEvent: Menu$ItemClickEvent) => void; - } - - /** - * Parameters of the Menu#afterClose event. - */ - export interface Menu$AfterCloseEventParameters {} - - /** - * Event object of the Menu#afterClose event. - */ - export type Menu$AfterCloseEvent = Event< - Menu$AfterCloseEventParameters, - Menu - >; - - /** - * Parameters of the Menu#afterOpen event. - */ - export interface Menu$AfterOpenEventParameters {} - - /** - * Event object of the Menu#afterOpen event. - */ - export type Menu$AfterOpenEvent = Event; - - /** - * Parameters of the Menu#beforeClose event. - */ - export interface Menu$BeforeCloseEventParameters { - /** - * Indicates that `ESC` key has triggered the event. - */ - escPressed?: boolean; - } - - /** - * Event object of the Menu#beforeClose event. - */ - export type Menu$BeforeCloseEvent = Event< - Menu$BeforeCloseEventParameters, - Menu - >; - - /** - * Parameters of the Menu#beforeOpen event. - */ - export interface Menu$BeforeOpenEventParameters { - /** - * The `sap.ui.webc.main.MenuItem` that triggers opening of the sub-menu or undefined when fired upon root - * menu opening. **Note:** available since 1.14.0. - */ - item?: HTMLElement; - } - - /** - * Event object of the Menu#beforeOpen event. - */ - export type Menu$BeforeOpenEvent = Event< - Menu$BeforeOpenEventParameters, - Menu - >; - - /** - * Parameters of the Menu#itemClick event. - */ - export interface Menu$ItemClickEventParameters { - /** - * The currently clicked menu item. - */ - item?: HTMLElement; - - /** - * The text of the currently clicked menu item. - */ - text?: string; - } - - /** - * Event object of the Menu#itemClick event. - */ - export type Menu$ItemClickEvent = Event; -} - -declare module "sap/ui/webc/main/MenuItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IMenuItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * `sap.ui.webc.main.MenuItem` is the item to use inside a `sap.ui.webc.main.Menu`. An arbitrary hierarchy - * structure can be represented by recursively nesting menu items. - * - * Usage: - * - * `sap.ui.webc.main.MenuItem` is an abstract element, representing a node in a `sap.ui.webc.main.Menu`. - * The menu itself is rendered as a list, and each `sap.ui.webc.main.MenuItem` is represented by a list - * item (`sap.ui.webc.main.StandardListItem`) in that list. Therefore, you should only use `sap.ui.webc.main.MenuItem` - * directly in your apps. The `sap.ui.webc.main.StandardListItem` list item is internal for the list, and - * not intended for public use. - * - * @since 1.102.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.102.0. This control is experimental and its API might change significantly. - */ - export default class MenuItem extends WebComponent implements IMenuItem { - __implements__sap_ui_webc_main_IMenuItem: boolean; - /** - * Constructor for a new `MenuItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MenuItemSettings - ); - /** - * Constructor for a new `MenuItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MenuItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.MenuItem with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.MenuItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IMenuItem - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the menu item. **Note:** The additional text would - * not be displayed if the item has a submenu. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getBusy busy}. - * - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover. - * - * Note: If set to `true` a `sap.ui.webc.main.BusyIndicator` component will be displayed into the related - * one to the current `sap.ui.webc.main.MenuItem` sub-menu popover. - * - * Default value is `false`. - * - * - * @returns Value of property `busy` - */ - getBusy(): boolean; - /** - * Gets current value of property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover. - * - * Default value is `1000`. - * - * - * @returns Value of property `busyDelay` - */ - getBusyDelay(): int; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon to be displayed as graphical element within the component. The SAP-icons font provides - * numerous options. - * - * *** Example:** See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of this component. - */ - getItems(): IMenuItem[]; - /** - * Gets current value of property {@link #getStartsSection startsSection}. - * - * Defines whether a visual separator should be rendered before the item. - * - * Default value is `false`. - * - * - * @returns Value of property `startsSection` - */ - getStartsSection(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the tree item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Checks for the provided `sap.ui.webc.main.IMenuItem` in the aggregation {@link #getItems items}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IMenuItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IMenuItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IMenuItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IMenuItem - ): IMenuItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the menu item. **Note:** The additional text would - * not be displayed if the item has a submenu. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText: string - ): this; - /** - * Sets a new value for property {@link #getBusy busy}. - * - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover. - * - * Note: If set to `true` a `sap.ui.webc.main.BusyIndicator` component will be displayed into the related - * one to the current `sap.ui.webc.main.MenuItem` sub-menu popover. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusy( - /** - * New value for property `busy` - */ - bBusy?: boolean - ): this; - /** - * Sets a new value for property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusyDelay( - /** - * New value for property `busyDelay` - */ - iBusyDelay?: int - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon to be displayed as graphical element within the component. The SAP-icons font provides - * numerous options. - * - * *** Example:** See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getStartsSection startsSection}. - * - * Defines whether a visual separator should be rendered before the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStartsSection( - /** - * New value for property `startsSection` - */ - bStartsSection?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the tree item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the MenuItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.102.0. This control is experimental and its API might change significantly. - */ - export interface $MenuItemSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the `additionalText`, displayed in the end of the menu item. **Note:** The additional text would - * not be displayed if the item has a submenu. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover. - * - * Note: If set to `true` a `sap.ui.webc.main.BusyIndicator` component will be displayed into the related - * one to the current `sap.ui.webc.main.MenuItem` sub-menu popover. - */ - busy?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the delay in milliseconds, after which the busy indicator will be displayed inside the corresponding - * ui5-menu popover. - */ - busyDelay?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon to be displayed as graphical element within the component. The SAP-icons font provides - * numerous options. - * - * *** Example:** See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether a visual separator should be rendered before the item. - */ - startsSection?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the tree item. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the items of this component. - */ - items?: IMenuItem[] | IMenuItem | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/MessageStrip" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Event from "sap/ui/base/Event"; - - import { MessageStripDesign, IIcon } from "sap/ui/webc/main/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.MessageStrip` component enables the embedding of app-related messages. It displays - * 4 designs of messages, each with corresponding semantic color and icon: Information, Positive, Warning - * and Negative. Each message can have a Close button, so that it can be removed from the UI, if needed. - * - * Usage: - * - * For the `sap.ui.webc.main.MessageStrip` component, you can define whether it displays an icon in the - * beginning and a close button. Moreover, its size and background can be controlled with CSS. - * - * Keyboard Handling: - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class MessageStrip extends WebComponent { - /** - * Constructor for a new `MessageStrip`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MessageStripSettings - ); - /** - * Constructor for a new `MessageStrip`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MessageStripSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.MessageStrip with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.MessageStrip. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.main.MessageStrip`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MessageStrip` itself. - * - * Fired when the close button is pressed either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MessageStrip` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.main.MessageStrip`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MessageStrip` itself. - * - * Fired when the close button is pressed either with a click/tap or by using the Enter or Space key. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MessageStrip` itself - */ - oListener?: object - ): this; - /** - * Destroys the icon in the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyIcon(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:close close} event of this `sap.ui.webc.main.MessageStrip`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:close close} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClose( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component type. - * - * Default value is `Information`. - * - * - * @returns Value of property `design` - */ - getDesign(): MessageStripDesign; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getHideCloseButton hideCloseButton}. - * - * Defines whether the MessageStrip renders close button. - * - * Default value is `false`. - * - * - * @returns Value of property `hideCloseButton` - */ - getHideCloseButton(): boolean; - /** - * Gets current value of property {@link #getHideIcon hideIcon}. - * - * Defines whether the MessageStrip will show an icon in the beginning. You can directly provide an icon - * with the `icon` slot. Otherwise, the default icon for the type will be used. - * - * Default value is `false`. - * - * - * @returns Value of property `hideIcon` - */ - getHideIcon(): boolean; - /** - * Gets content of aggregation {@link #getIcon icon}. - * - * Defines the content to be displayed as graphical element within the component. - * - * **Note:** If no icon is given, the default icon for the component type will be used. The SAP-icons font - * provides numerous options. - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - getIcon(): IIcon; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component type. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Information`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: MessageStripDesign | keyof typeof MessageStripDesign - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getHideCloseButton hideCloseButton}. - * - * Defines whether the MessageStrip renders close button. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideCloseButton( - /** - * New value for property `hideCloseButton` - */ - bHideCloseButton?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideIcon hideIcon}. - * - * Defines whether the MessageStrip will show an icon in the beginning. You can directly provide an icon - * with the `icon` slot. Otherwise, the default icon for the type will be used. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideIcon( - /** - * New value for property `hideIcon` - */ - bHideIcon?: boolean - ): this; - /** - * Sets the aggregated {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * The icon to set - */ - oIcon: IIcon - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the MessageStrip constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $MessageStripSettings extends $WebComponentSettings { - /** - * Defines the component type. - */ - design?: - | (MessageStripDesign | keyof typeof MessageStripDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the MessageStrip renders close button. - */ - hideCloseButton?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the MessageStrip will show an icon in the beginning. You can directly provide an icon - * with the `icon` slot. Otherwise, the default icon for the type will be used. - */ - hideIcon?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content to be displayed as graphical element within the component. - * - * **Note:** If no icon is given, the default icon for the component type will be used. The SAP-icons font - * provides numerous options. - * - * - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: IIcon; - - /** - * Fired when the close button is pressed either with a click/tap or by using the Enter or Space key. - */ - close?: (oEvent: Event) => void; - } - - /** - * Parameters of the MessageStrip#close event. - */ - export interface MessageStrip$CloseEventParameters {} - - /** - * Event object of the MessageStrip#close event. - */ - export type MessageStrip$CloseEvent = Event< - MessageStrip$CloseEventParameters, - MessageStrip - >; -} - -declare module "sap/ui/webc/main/MultiComboBox" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { - IIcon, - IMultiComboBoxItem, - ComboBoxFilter, - } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.MultiComboBox` component consists of a list box with items and a text field allowing - * the user to either type a value directly into the text field, or choose from the list of existing items. - * - * The drop-down list is used for selecting and filtering values, it enables users to select one or more - * options from a predefined list. The control provides an editable input field to filter the list, and - * a dropdown arrow to expand/collapse the list of available options. The options in the list have checkboxes - * that permit multi-selection. Entered values are displayed as tokens. Structure: The `sap.ui.webc.main.MultiComboBox` - * consists of the following elements: - * - Tokenizer - a list of tokens with selected options. - * - Input field - displays the selected option/s as token/s. Users can type to filter the list. - * - Drop-down arrow - expands\collapses the option list. - * - Option list - the list of available options. Keyboard Handling: - * - * The `sap.ui.webc.main.MultiComboBox` provides advanced keyboard handling. - * - * Picker: If the `sap.ui.webc.main.MultiComboBox` is focused, you can open or close the drop-down by pressing - * `F4`, `ALT+UP` or `ALT+DOWN` keys. Once the drop-down is opened, you can use the `UP` and `DOWN` arrow - * keys to navigate through the available options and select one by pressing the `Space` or `Enter` keys. - * - * - * - * Tokens: - * - Left/Right arrow keys - moves the focus selection form the currently focused token to the previous/next - * one (if available). - * - Delete - deletes the token and focuses the previous token. - * - Backspace - deletes the token and focus the next token. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.MultiComboBox` exposes the following CSS Shadow Parts: - * - token-{index} - Used to style each token(where `token-0` corresponds to the first item) - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class MultiComboBox - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `MultiComboBox`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MultiComboBoxSettings - ); - /** - * Constructor for a new `MultiComboBox`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MultiComboBoxSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.MultiComboBox with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.MultiComboBox. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some icon to the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addIcon( - /** - * The icon to add; if empty, nothing is inserted - */ - oIcon: IIcon - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IMultiComboBoxItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when the value of the component changes at each keystroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when the value of the component changes at each keystroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:openChange openChange} event of this `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when the dropdown is opened or closed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOpenChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:openChange openChange} event of this `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when the dropdown is opened or closed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOpenChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiComboBox$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.MultiComboBox`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiComboBox` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiComboBox$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiComboBox` itself - */ - oListener?: object - ): this; - /** - * Destroys all the icon in the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyIcon(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.MultiComboBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.MultiComboBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:openChange openChange} event of this `sap.ui.webc.main.MultiComboBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachOpenChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.main.MultiComboBox`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: MultiComboBox$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:openChange openChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireOpenChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: MultiComboBox$SelectionChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAllowCustomValues allowCustomValues}. - * - * Defines if the user input will be prevented, if no matching item has been found - * - * Default value is `false`. - * - * - * @returns Value of property `allowCustomValues` - */ - getAllowCustomValues(): boolean; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getFilter filter}. - * - * Defines the filter type of the component. Available options are: `StartsWithPerTerm`, `StartsWith`, `Contains` - * and `None`. - * - * Default value is `StartsWithPerTerm`. - * - * - * @returns Value of property `filter` - */ - getFilter(): ComboBoxFilter; - /** - * Gets content of aggregation {@link #getIcon icon}. - * - * Defines the icon to be displayed in the component. - */ - getIcon(): IIcon[]; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the component items. - */ - getItems(): IMultiComboBoxItem[]; - /** - * Gets current value of property {@link #getNoTypeahead noTypeahead}. - * - * Defines whether the value will be autcompleted to match an item - * - * Default value is `false`. - * - * - * @returns Value of property `noTypeahead` - */ - getNoTypeahead(): boolean; - /** - * Returns the indicates whether the dropdown is open. True if the dropdown is open, false otherwise. - */ - getOpen(): void; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Available options are: - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.IIcon` in the aggregation {@link #getIcon icon}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfIcon( - /** - * The icon whose index is looked for - */ - oIcon: IIcon - ): int; - /** - * Checks for the provided `sap.ui.webc.main.IMultiComboBoxItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IMultiComboBoxItem - ): int; - /** - * Inserts a icon into the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertIcon( - /** - * The icon to insert; if empty, nothing is inserted - */ - oIcon: IIcon, - /** - * The `0`-based index the icon should be inserted at; for a negative value of `iIndex`, the icon is inserted - * at position 0; for a value greater than the current size of the aggregation, the icon is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IMultiComboBoxItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getIcon icon}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllIcon(): IIcon[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IMultiComboBoxItem[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a icon from the aggregation {@link #getIcon icon}. - * - * - * @returns The removed icon or `null` - */ - removeIcon( - /** - * The icon to remove or its index or id - */ - vIcon: int | string | IIcon - ): IIcon | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IMultiComboBoxItem - ): IMultiComboBoxItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAllowCustomValues allowCustomValues}. - * - * Defines if the user input will be prevented, if no matching item has been found - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAllowCustomValues( - /** - * New value for property `allowCustomValues` - */ - bAllowCustomValues?: boolean - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getFilter filter}. - * - * Defines the filter type of the component. Available options are: `StartsWithPerTerm`, `StartsWith`, `Contains` - * and `None`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `StartsWithPerTerm`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFilter( - /** - * New value for property `filter` - */ - sFilter?: ComboBoxFilter | keyof typeof ComboBoxFilter - ): this; - /** - * Sets a new value for property {@link #getNoTypeahead noTypeahead}. - * - * Defines whether the value will be autcompleted to match an item - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoTypeahead( - /** - * New value for property `noTypeahead` - */ - bNoTypeahead?: boolean - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Available options are: - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the MultiComboBox constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $MultiComboBoxSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines if the user input will be prevented, if no matching item has been found - */ - allowCustomValues?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the filter type of the component. Available options are: `StartsWithPerTerm`, `StartsWith`, `Contains` - * and `None`. - */ - filter?: - | (ComboBoxFilter | keyof typeof ComboBoxFilter) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the value will be autcompleted to match an item - */ - noTypeahead?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a short hint intended to aid the user with data entry when the component has no value. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - * - * Available options are: - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon to be displayed in the component. - */ - icon?: IIcon[] | IIcon | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the component items. - */ - items?: - | IMultiComboBoxItem[] - | IMultiComboBoxItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter or on focusout. - */ - change?: (oEvent: Event) => void; - - /** - * Fired when the value of the component changes at each keystroke. - */ - input?: (oEvent: Event) => void; - - /** - * Fired when the dropdown is opened or closed. - */ - openChange?: (oEvent: Event) => void; - - /** - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - */ - selectionChange?: (oEvent: MultiComboBox$SelectionChangeEvent) => void; - } - - /** - * Parameters of the MultiComboBox#change event. - */ - export interface MultiComboBox$ChangeEventParameters {} - - /** - * Event object of the MultiComboBox#change event. - */ - export type MultiComboBox$ChangeEvent = Event< - MultiComboBox$ChangeEventParameters, - MultiComboBox - >; - - /** - * Parameters of the MultiComboBox#input event. - */ - export interface MultiComboBox$InputEventParameters {} - - /** - * Event object of the MultiComboBox#input event. - */ - export type MultiComboBox$InputEvent = Event< - MultiComboBox$InputEventParameters, - MultiComboBox - >; - - /** - * Parameters of the MultiComboBox#openChange event. - */ - export interface MultiComboBox$OpenChangeEventParameters {} - - /** - * Event object of the MultiComboBox#openChange event. - */ - export type MultiComboBox$OpenChangeEvent = Event< - MultiComboBox$OpenChangeEventParameters, - MultiComboBox - >; - - /** - * Parameters of the MultiComboBox#selectionChange event. - */ - export interface MultiComboBox$SelectionChangeEventParameters { - /** - * an array of the selected items. - */ - items?: any[]; - } - - /** - * Event object of the MultiComboBox#selectionChange event. - */ - export type MultiComboBox$SelectionChangeEvent = Event< - MultiComboBox$SelectionChangeEventParameters, - MultiComboBox - >; -} - -declare module "sap/ui/webc/main/MultiComboBoxGroupItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IMultiComboBoxItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.MultiComboBoxGroupItem` is type of suggestion item, that can be used to split the - * `sap.ui.webc.main.MultiComboBox` suggestions into groups. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class MultiComboBoxGroupItem - extends WebComponent - implements IMultiComboBoxItem - { - __implements__sap_ui_webc_main_IMultiComboBoxItem: boolean; - /** - * Constructor for a new `MultiComboBoxGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MultiComboBoxGroupItemSettings - ); - /** - * Constructor for a new `MultiComboBoxGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MultiComboBoxGroupItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.MultiComboBoxGroupItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.MultiComboBoxGroupItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the MultiComboBoxGroupItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $MultiComboBoxGroupItemSettings - extends $WebComponentSettings { - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/MultiComboBoxItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IMultiComboBoxItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.MultiComboBoxItem` represents the item for a `sap.ui.webc.main.MultiComboBox`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class MultiComboBoxItem - extends WebComponent - implements IMultiComboBoxItem - { - __implements__sap_ui_webc_main_IMultiComboBoxItem: boolean; - /** - * Constructor for a new `MultiComboBoxItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MultiComboBoxItemSettings - ); - /** - * Constructor for a new `MultiComboBoxItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MultiComboBoxItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.MultiComboBoxItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.MultiComboBoxItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the additional text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the additional text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText?: string - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the MultiComboBoxItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $MultiComboBoxItemSettings extends $WebComponentSettings { - /** - * Defines the additional text of the component. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the selected state of the component. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/MultiInput" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - IFormContent, - ISemanticFormContent, - ID, - ValueState, - CSSSize, - } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { - IIcon, - IInputSuggestionItem, - IToken, - InputType, - } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: A `sap.ui.webc.main.MultiInput` field allows the user to enter multiple values, which are displayed - * as `sap.ui.webc.main.Token`. - * - * User can choose interaction for creating tokens. Fiori Guidelines say that user should create tokens - * when: - * - Type a value in the input and press enter or focus out the input field (`change` event is fired) - * - * - Select a value from the suggestion list (`suggestion-item-select` event is fired) - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class MultiInput - extends WebComponent - implements IFormContent, ISemanticFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - __implements__sap_ui_core_ISemanticFormContent: boolean; - /** - * Constructor for a new `MultiInput`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $MultiInputSettings - ); - /** - * Constructor for a new `MultiInput`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $MultiInputSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.MultiInput with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.MultiInput. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some icon to the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addIcon( - /** - * The icon to add; if empty, nothing is inserted - */ - oIcon: IIcon - ): this; - /** - * Adds some suggestionItem to the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addSuggestionItem( - /** - * The suggestionItem to add; if empty, nothing is inserted - */ - oSuggestionItem: IInputSuggestionItem - ): this; - /** - * Adds some token to the aggregation {@link #getTokens tokens}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addToken( - /** - * The token to add; if empty, nothing is inserted - */ - oToken: IToken - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the value of the component changes at each keystroke, and when a suggestion item has been - * selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the value of the component changes at each keystroke, and when a suggestion item has been - * selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemPreview suggestionItemPreview } - * event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the user navigates to a suggestion item via the ARROW keys, as a preview, before the final - * selection. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemPreview( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiInput$SuggestionItemPreviewEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemPreview suggestionItemPreview } - * event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the user navigates to a suggestion item via the ARROW keys, as a preview, before the final - * selection. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemPreview( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiInput$SuggestionItemPreviewEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemSelect suggestionItemSelect} event - * of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when a suggestion item, that is displayed in the suggestion popup, is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemSelect( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiInput$SuggestionItemSelectEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:suggestionItemSelect suggestionItemSelect} event - * of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when a suggestion item, that is displayed in the suggestion popup, is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSuggestionItemSelect( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiInput$SuggestionItemSelectEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:tokenDelete tokenDelete} event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when a token is about to be deleted. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachTokenDelete( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiInput$TokenDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:tokenDelete tokenDelete} event of this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when a token is about to be deleted. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachTokenDelete( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: MultiInput$TokenDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:valueHelpTrigger valueHelpTrigger} event of - * this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the value help icon is pressed and F4 or ALT/OPTION + ARROW_UP/ARROW_DOWN keyboard keys are - * used. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachValueHelpTrigger( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:valueHelpTrigger valueHelpTrigger} event of - * this `sap.ui.webc.main.MultiInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.MultiInput` itself. - * - * Fired when the value help icon is pressed and F4 or ALT/OPTION + ARROW_UP/ARROW_DOWN keyboard keys are - * used. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachValueHelpTrigger( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.MultiInput` itself - */ - oListener?: object - ): this; - /** - * Destroys all the icon in the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyIcon(): this; - /** - * Destroys all the suggestionItems in the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySuggestionItems(): this; - /** - * Destroys all the tokens in the aggregation {@link #getTokens tokens}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyTokens(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.MultiInput`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.MultiInput`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:suggestionItemPreview suggestionItemPreview } - * event of this `sap.ui.webc.main.MultiInput`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSuggestionItemPreview( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: MultiInput$SuggestionItemPreviewEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:suggestionItemSelect suggestionItemSelect } - * event of this `sap.ui.webc.main.MultiInput`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSuggestionItemSelect( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: MultiInput$SuggestionItemSelectEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:tokenDelete tokenDelete} event of this `sap.ui.webc.main.MultiInput`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachTokenDelete( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: MultiInput$TokenDeleteEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:valueHelpTrigger valueHelpTrigger} event of - * this `sap.ui.webc.main.MultiInput`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachValueHelpTrigger( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:suggestionItemPreview suggestionItemPreview} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSuggestionItemPreview( - /** - * Parameters to pass along with the event - */ - mParameters?: MultiInput$SuggestionItemPreviewEventParameters - ): this; - /** - * Fires event {@link #event:suggestionItemSelect suggestionItemSelect} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSuggestionItemSelect( - /** - * Parameters to pass along with the event - */ - mParameters?: MultiInput$SuggestionItemSelectEventParameters - ): this; - /** - * Fires event {@link #event:tokenDelete tokenDelete} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireTokenDelete( - /** - * Parameters to pass along with the event - */ - mParameters?: MultiInput$TokenDeleteEventParameters - ): this; - /** - * Fires event {@link #event:valueHelpTrigger valueHelpTrigger} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireValueHelpTrigger( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets content of aggregation {@link #getIcon icon}. - * - * Defines the icon to be displayed in the component. - */ - getIcon(): IIcon[]; - /** - * Gets current value of property {@link #getMaxlength maxlength}. - * - * Sets the maximum number of characters available in the input field. - * - * **Note:** This property is not compatible with the ui5-input type InputType.Number. If the ui5-input - * type is set to Number, the maxlength value is ignored. - * - * - * @returns Value of property `maxlength` - */ - getMaxlength(): int; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getNoTypeahead noTypeahead}. - * - * Defines whether the value will be autcompleted to match an item - * - * Default value is `false`. - * - * - * @returns Value of property `noTypeahead` - */ - getNoTypeahead(): boolean; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Returns the the suggestion item on preview. - */ - getPreviewItem(): void; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getShowClearIcon showClearIcon}. - * - * Defines whether the clear icon of the input will be shown. - * - * Default value is `false`. - * - * - * @returns Value of property `showClearIcon` - */ - getShowClearIcon(): boolean; - /** - * Gets current value of property {@link #getShowSuggestions showSuggestions}. - * - * Defines whether the component should show suggestions, if such are present. - * - * **Note:** You need to import the `InputSuggestions` module from `"@ui5/webcomponents/dist/features/InputSuggestions.js"` - * to enable this functionality. - * - * Default value is `false`. - * - * - * @returns Value of property `showSuggestions` - */ - getShowSuggestions(): boolean; - /** - * Gets current value of property {@link #getShowValueHelpIcon showValueHelpIcon}. - * - * Determines whether a value help icon will be visualized in the end of the input. Pressing the icon will - * fire `value-help-trigger` event. - * - * Default value is `false`. - * - * - * @returns Value of property `showValueHelpIcon` - */ - getShowValueHelpIcon(): boolean; - /** - * Gets content of aggregation {@link #getSuggestionItems suggestionItems}. - */ - getSuggestionItems(): IInputSuggestionItem[]; - /** - * Gets content of aggregation {@link #getTokens tokens}. - * - * Defines the component tokens. - */ - getTokens(): IToken[]; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the HTML type of the component. - * - * **Notes:** - * - The particular effect of this property differs depending on the browser and the current language - * settings, especially for type `Number`. - * - The property is mostly intended to be used with touch devices that use different soft keyboard layouts - * depending on the given input type. - * - * Default value is `Text`. - * - * - * @returns Value of property `type` - */ - getType(): InputType; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.IIcon` in the aggregation {@link #getIcon icon}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfIcon( - /** - * The icon whose index is looked for - */ - oIcon: IIcon - ): int; - /** - * Checks for the provided `sap.ui.webc.main.IInputSuggestionItem` in the aggregation {@link #getSuggestionItems suggestionItems}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfSuggestionItem( - /** - * The suggestionItem whose index is looked for - */ - oSuggestionItem: IInputSuggestionItem - ): int; - /** - * Checks for the provided `sap.ui.webc.main.IToken` in the aggregation {@link #getTokens tokens}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfToken( - /** - * The token whose index is looked for - */ - oToken: IToken - ): int; - /** - * Inserts a icon into the aggregation {@link #getIcon icon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertIcon( - /** - * The icon to insert; if empty, nothing is inserted - */ - oIcon: IIcon, - /** - * The `0`-based index the icon should be inserted at; for a negative value of `iIndex`, the icon is inserted - * at position 0; for a value greater than the current size of the aggregation, the icon is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Inserts a suggestionItem into the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertSuggestionItem( - /** - * The suggestionItem to insert; if empty, nothing is inserted - */ - oSuggestionItem: IInputSuggestionItem, - /** - * The `0`-based index the suggestionItem should be inserted at; for a negative value of `iIndex`, the suggestionItem - * is inserted at position 0; for a value greater than the current size of the aggregation, the suggestionItem - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a token into the aggregation {@link #getTokens tokens}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertToken( - /** - * The token to insert; if empty, nothing is inserted - */ - oToken: IToken, - /** - * The `0`-based index the token should be inserted at; for a negative value of `iIndex`, the token is inserted - * at position 0; for a value greater than the current size of the aggregation, the token is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Manually opens the suggestions popover, assuming suggestions are enabled. Items must be preloaded for - * it to open. - */ - openPicker(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getIcon icon}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllIcon(): IIcon[]; - /** - * Removes all the controls from the aggregation {@link #getSuggestionItems suggestionItems}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllSuggestionItems(): IInputSuggestionItem[]; - /** - * Removes all the controls from the aggregation {@link #getTokens tokens}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllTokens(): IToken[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a icon from the aggregation {@link #getIcon icon}. - * - * - * @returns The removed icon or `null` - */ - removeIcon( - /** - * The icon to remove or its index or id - */ - vIcon: int | string | IIcon - ): IIcon | null; - /** - * Removes a suggestionItem from the aggregation {@link #getSuggestionItems suggestionItems}. - * - * - * @returns The removed suggestionItem or `null` - */ - removeSuggestionItem( - /** - * The suggestionItem to remove or its index or id - */ - vSuggestionItem: int | string | IInputSuggestionItem - ): IInputSuggestionItem | null; - /** - * Removes a token from the aggregation {@link #getTokens tokens}. - * - * - * @returns The removed token or `null` - */ - removeToken( - /** - * The token to remove or its index or id - */ - vToken: int | string | IToken - ): IToken | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getMaxlength maxlength}. - * - * Sets the maximum number of characters available in the input field. - * - * **Note:** This property is not compatible with the ui5-input type InputType.Number. If the ui5-input - * type is set to Number, the maxlength value is ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMaxlength( - /** - * New value for property `maxlength` - */ - iMaxlength: int - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getNoTypeahead noTypeahead}. - * - * Defines whether the value will be autcompleted to match an item - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoTypeahead( - /** - * New value for property `noTypeahead` - */ - bNoTypeahead?: boolean - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowClearIcon showClearIcon}. - * - * Defines whether the clear icon of the input will be shown. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowClearIcon( - /** - * New value for property `showClearIcon` - */ - bShowClearIcon?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowSuggestions showSuggestions}. - * - * Defines whether the component should show suggestions, if such are present. - * - * **Note:** You need to import the `InputSuggestions` module from `"@ui5/webcomponents/dist/features/InputSuggestions.js"` - * to enable this functionality. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowSuggestions( - /** - * New value for property `showSuggestions` - */ - bShowSuggestions?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowValueHelpIcon showValueHelpIcon}. - * - * Determines whether a value help icon will be visualized in the end of the input. Pressing the icon will - * fire `value-help-trigger` event. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowValueHelpIcon( - /** - * New value for property `showValueHelpIcon` - */ - bShowValueHelpIcon?: boolean - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the HTML type of the component. - * - * **Notes:** - * - The particular effect of this property differs depending on the browser and the current language - * settings, especially for type `Number`. - * - The property is mostly intended to be used with touch devices that use different soft keyboard layouts - * depending on the given input type. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Text`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: InputType | keyof typeof InputType - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the MultiInput constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $MultiInputSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Sets the maximum number of characters available in the input field. - * - * **Note:** This property is not compatible with the ui5-input type InputType.Number. If the ui5-input - * type is set to Number, the maxlength value is ignored. - */ - maxlength?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines whether the value will be autcompleted to match an item - */ - noTypeahead?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a short hint intended to aid the user with data entry when the component has no value. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the clear icon of the input will be shown. - */ - showClearIcon?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component should show suggestions, if such are present. - * - * **Note:** You need to import the `InputSuggestions` module from `"@ui5/webcomponents/dist/features/InputSuggestions.js"` - * to enable this functionality. - */ - showSuggestions?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines whether a value help icon will be visualized in the end of the input. Pressing the icon will - * fire `value-help-trigger` event. - */ - showValueHelpIcon?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the HTML type of the component. - * - * **Notes:** - * - The particular effect of this property differs depending on the browser and the current language - * settings, especially for type `Number`. - * - The property is mostly intended to be used with touch devices that use different soft keyboard layouts - * depending on the given input type. - */ - type?: - | (InputType | keyof typeof InputType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value of the component. - * - * **Note:** The property is updated upon typing. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon to be displayed in the component. - */ - icon?: IIcon[] | IIcon | AggregationBindingInfo | `{${string}}`; - - suggestionItems?: - | IInputSuggestionItem[] - | IInputSuggestionItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Defines the component tokens. - */ - tokens?: IToken[] | IToken | AggregationBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter or on focusout. - */ - change?: (oEvent: Event) => void; - - /** - * Fired when the value of the component changes at each keystroke, and when a suggestion item has been - * selected. - */ - input?: (oEvent: Event) => void; - - /** - * Fired when the user navigates to a suggestion item via the ARROW keys, as a preview, before the final - * selection. - */ - suggestionItemPreview?: ( - oEvent: MultiInput$SuggestionItemPreviewEvent - ) => void; - - /** - * Fired when a suggestion item, that is displayed in the suggestion popup, is selected. - */ - suggestionItemSelect?: ( - oEvent: MultiInput$SuggestionItemSelectEvent - ) => void; - - /** - * Fired when a token is about to be deleted. - */ - tokenDelete?: (oEvent: MultiInput$TokenDeleteEvent) => void; - - /** - * Fired when the value help icon is pressed and F4 or ALT/OPTION + ARROW_UP/ARROW_DOWN keyboard keys are - * used. - */ - valueHelpTrigger?: (oEvent: Event) => void; - } - - /** - * Parameters of the MultiInput#change event. - */ - export interface MultiInput$ChangeEventParameters {} - - /** - * Event object of the MultiInput#change event. - */ - export type MultiInput$ChangeEvent = Event< - MultiInput$ChangeEventParameters, - MultiInput - >; - - /** - * Parameters of the MultiInput#input event. - */ - export interface MultiInput$InputEventParameters {} - - /** - * Event object of the MultiInput#input event. - */ - export type MultiInput$InputEvent = Event< - MultiInput$InputEventParameters, - MultiInput - >; - - /** - * Parameters of the MultiInput#suggestionItemPreview event. - */ - export interface MultiInput$SuggestionItemPreviewEventParameters { - /** - * The previewed suggestion item. - */ - item?: HTMLElement; - - /** - * The DOM ref of the suggestion item. - */ - targetRef?: HTMLElement; - } - - /** - * Event object of the MultiInput#suggestionItemPreview event. - */ - export type MultiInput$SuggestionItemPreviewEvent = Event< - MultiInput$SuggestionItemPreviewEventParameters, - MultiInput - >; - - /** - * Parameters of the MultiInput#suggestionItemSelect event. - */ - export interface MultiInput$SuggestionItemSelectEventParameters { - /** - * The selected item. - */ - item?: HTMLElement; - } - - /** - * Event object of the MultiInput#suggestionItemSelect event. - */ - export type MultiInput$SuggestionItemSelectEvent = Event< - MultiInput$SuggestionItemSelectEventParameters, - MultiInput - >; - - /** - * Parameters of the MultiInput#tokenDelete event. - */ - export interface MultiInput$TokenDeleteEventParameters { - /** - * deleted token. - */ - token?: HTMLElement; - } - - /** - * Event object of the MultiInput#tokenDelete event. - */ - export type MultiInput$TokenDeleteEvent = Event< - MultiInput$TokenDeleteEventParameters, - MultiInput - >; - - /** - * Parameters of the MultiInput#valueHelpTrigger event. - */ - export interface MultiInput$ValueHelpTriggerEventParameters {} - - /** - * Event object of the MultiInput#valueHelpTrigger event. - */ - export type MultiInput$ValueHelpTriggerEvent = Event< - MultiInput$ValueHelpTriggerEventParameters, - MultiInput - >; -} - -declare module "sap/ui/webc/main/Option" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ISelectOption } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Option` component defines the content of an option in the `sap.ui.webc.main.Select`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Option extends WebComponent implements ISelectOption { - __implements__sap_ui_webc_main_ISelectOption: boolean; - /** - * Constructor for a new `Option`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $OptionSettings - ); - /** - * Constructor for a new `Option`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $OptionSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Option with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Option. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the additional text displayed at the end of the option element. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the value of the `sap.ui.webc.main.Select` inside an HTML Form element when this component is - * selected. For more information on HTML Form support, see the `name` property of `sap.ui.webc.main.Select`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the additional text displayed at the end of the option element. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon: string - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the value of the `sap.ui.webc.main.Select` inside an HTML Form element when this component is - * selected. For more information on HTML Form support, see the `name` property of `sap.ui.webc.main.Select`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue: string - ): this; - } - /** - * Describes the settings that can be provided to the Option constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $OptionSettings extends $WebComponentSettings { - /** - * Defines the additional text displayed at the end of the option element. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the selected state of the component. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the value of the `sap.ui.webc.main.Select` inside an HTML Form element when this component is - * selected. For more information on HTML Form support, see the `name` property of `sap.ui.webc.main.Select`. - */ - value?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/Panel" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { PanelAccessibleRole, TitleLevel } from "sap/ui/webc/main/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Panel` component is a container which has a header and a content area and is used - * for grouping and displaying information. It can be collapsed to save space on the screen. - * - * Guidelines:: - * - Nesting two or more panels is not recommended. - * - Do not stack too many panels on one page. - * - * Structure: The panel's header area consists of a title bar with a header text or custom header. - * The header is clickable and can be used to toggle between the expanded and collapsed state. It includes - * an icon which rotates depending on the state. - * The custom header can be set through the `header` slot and it may contain arbitraray content, such as: - * title, buttons or any other HTML elements. - * The content area can contain an arbitrary set of controls. - * **Note:** The custom header is not clickable out of the box, but in this case the icon is interactive - * and allows to show/hide the content area. - * - * Responsive Behavior: - * - If the width of the panel is set to 100% (default), the panel and its children are resized responsively, - * depending on its parent container. - * - If the panel has a fixed height, it will take up the space even if the panel is collapsed. - * - When the panel is expandable (the `fixed` property is set to `false`), an arrow icon (pointing to - * the right) appears in front of the header. - * - When the animation is activated, expand/collapse uses a smooth animation to open or close the content - * area. - * - When the panel expands/collapses, the arrow icon rotates 90 degrees clockwise/counter-clockwise. - * - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Panel` exposes the following CSS Shadow Parts: - * - header - Used to style the wrapper of the header - * - content - Used to style the wrapper of the content - * - * Keyboard Handling: - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Panel extends WebComponent { - /** - * Constructor for a new `Panel`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $PanelSettings - ); - /** - * Constructor for a new `Panel`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $PanelSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Panel with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Panel. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:toggle toggle} event of this `sap.ui.webc.main.Panel`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Panel` itself. - * - * Fired when the component is expanded/collapsed by user interaction. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachToggle( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Panel` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:toggle toggle} event of this `sap.ui.webc.main.Panel`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Panel` itself. - * - * Fired when the component is expanded/collapsed by user interaction. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachToggle( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Panel` itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:toggle toggle} event of this `sap.ui.webc.main.Panel`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachToggle( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:toggle toggle} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireToggle( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAccessibleRole accessibleRole}. - * - * Sets the accessible ARIA role of the component. Depending on the usage, you can change the role from - * the default `Form` to `Region` or `Complementary`. - * - * Default value is `Form`. - * - * - * @returns Value of property `accessibleRole` - */ - getAccessibleRole(): PanelAccessibleRole; - /** - * Gets current value of property {@link #getCollapsed collapsed}. - * - * Indicates whether the component is collapsed and only the header is displayed. - * - * Default value is `false`. - * - * - * @returns Value of property `collapsed` - */ - getCollapsed(): boolean; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the component. The content is visible only when the component is expanded. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getFixed fixed}. - * - * Determines whether the component is in a fixed state that is not expandable/collapsible by user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `fixed` - */ - getFixed(): boolean; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the component header area. - * - * **Note:** When a header is provided, the `headerText` property is ignored. - */ - getHeader(): Control[]; - /** - * Gets current value of property {@link #getHeaderLevel headerLevel}. - * - * Defines the "aria-level" of component heading, set by the `headerText`. - * - * Available options are: `"H6"` to `"H1"`. - * - * Default value is `H2`. - * - * - * @returns Value of property `headerLevel` - */ - getHeaderLevel(): TitleLevel; - /** - * Gets current value of property {@link #getHeaderText headerText}. - * - * This property is used to set the header text of the component. The text is visible in both expanded and - * collapsed states. - * - * **Note:** This property is overridden by the `header` slot. - * - * Default value is `empty string`. - * - * - * @returns Value of property `headerText` - */ - getHeaderText(): string; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getNoAnimation noAnimation}. - * - * Indicates whether the transition between the expanded and the collapsed state of the component is animated. - * By default the animation is enabled. - * - * Default value is `false`. - * - * - * @returns Value of property `noAnimation` - */ - getNoAnimation(): boolean; - /** - * Gets current value of property {@link #getStickyHeader stickyHeader}. - * - * Indicates whether the Panel header is sticky or not. If stickyHeader is set to true, then whenever you - * scroll the content or the application, the header of the panel will be always visible and a solid color - * will be used for its design. - * - * Default value is `false`. - * - * - * @returns Value of property `stickyHeader` - */ - getStickyHeader(): boolean; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAccessibleRole accessibleRole}. - * - * Sets the accessible ARIA role of the component. Depending on the usage, you can change the role from - * the default `Form` to `Region` or `Complementary`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Form`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleRole( - /** - * New value for property `accessibleRole` - */ - sAccessibleRole?: PanelAccessibleRole | keyof typeof PanelAccessibleRole - ): this; - /** - * Sets a new value for property {@link #getCollapsed collapsed}. - * - * Indicates whether the component is collapsed and only the header is displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setCollapsed( - /** - * New value for property `collapsed` - */ - bCollapsed?: boolean - ): this; - /** - * Sets a new value for property {@link #getFixed fixed}. - * - * Determines whether the component is in a fixed state that is not expandable/collapsible by user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFixed( - /** - * New value for property `fixed` - */ - bFixed?: boolean - ): this; - /** - * Sets a new value for property {@link #getHeaderLevel headerLevel}. - * - * Defines the "aria-level" of component heading, set by the `headerText`. - * - * Available options are: `"H6"` to `"H1"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `H2`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderLevel( - /** - * New value for property `headerLevel` - */ - sHeaderLevel?: TitleLevel | keyof typeof TitleLevel - ): this; - /** - * Sets a new value for property {@link #getHeaderText headerText}. - * - * This property is used to set the header text of the component. The text is visible in both expanded and - * collapsed states. - * - * **Note:** This property is overridden by the `header` slot. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderText( - /** - * New value for property `headerText` - */ - sHeaderText?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getNoAnimation noAnimation}. - * - * Indicates whether the transition between the expanded and the collapsed state of the component is animated. - * By default the animation is enabled. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoAnimation( - /** - * New value for property `noAnimation` - */ - bNoAnimation?: boolean - ): this; - /** - * Sets a new value for property {@link #getStickyHeader stickyHeader}. - * - * Indicates whether the Panel header is sticky or not. If stickyHeader is set to true, then whenever you - * scroll the content or the application, the header of the panel will be always visible and a solid color - * will be used for its design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStickyHeader( - /** - * New value for property `stickyHeader` - */ - bStickyHeader?: boolean - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Panel constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $PanelSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Sets the accessible ARIA role of the component. Depending on the usage, you can change the role from - * the default `Form` to `Region` or `Complementary`. - */ - accessibleRole?: - | (PanelAccessibleRole | keyof typeof PanelAccessibleRole) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Indicates whether the component is collapsed and only the header is displayed. - */ - collapsed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines whether the component is in a fixed state that is not expandable/collapsible by user interaction. - */ - fixed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the "aria-level" of component heading, set by the `headerText`. - * - * Available options are: `"H6"` to `"H1"`. - */ - headerLevel?: - | (TitleLevel | keyof typeof TitleLevel) - | PropertyBindingInfo - | `{${string}}`; - - /** - * This property is used to set the header text of the component. The text is visible in both expanded and - * collapsed states. - * - * **Note:** This property is overridden by the `header` slot. - */ - headerText?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Indicates whether the transition between the expanded and the collapsed state of the component is animated. - * By default the animation is enabled. - */ - noAnimation?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Indicates whether the Panel header is sticky or not. If stickyHeader is set to true, then whenever you - * scroll the content or the application, the header of the panel will be always visible and a solid color - * will be used for its design. - */ - stickyHeader?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the component. The content is visible only when the component is expanded. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the component header area. - * - * **Note:** When a header is provided, the `headerText` property is ignored. - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the component is expanded/collapsed by user interaction. - */ - toggle?: (oEvent: Event) => void; - } - - /** - * Parameters of the Panel#toggle event. - */ - export interface Panel$ToggleEventParameters {} - - /** - * Event object of the Panel#toggle event. - */ - export type Panel$ToggleEvent = Event; -} - -declare module "sap/ui/webc/main/Popover" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { - PopupAccessibleRole, - PopoverHorizontalAlign, - PopoverPlacementType, - PopoverVerticalAlign, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Popover` component displays additional information for an object in a compact way - * and without leaving the page. The Popover can contain various UI elements, such as fields, tables, images, - * and charts. It can also include actions in the footer. - * - * Structure: - * - * The popover has three main areas: - * - Header (optional) - * - Content - * - Footer (optional) - * - * **Note:** The `sap.ui.webc.main.Popover` is closed when the user clicks or taps outside the popover or - * selects an action within the popover. You can prevent this with the `modal` property. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Popover` exposes the following CSS Shadow Parts: - * - header - Used to style the header of the component - * - content - Used to style the content of the component - * - footer - Used to style the footer of the component - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Popover extends WebComponent { - /** - * Constructor for a new `Popover`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $PopoverSettings - ); - /** - * Constructor for a new `Popover`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $PopoverSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Popover with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Popover. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some footer to the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addFooter( - /** - * The footer to add; if empty, nothing is inserted - */ - oFooter: Control - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Focuses the element denoted by `initialFocus`, if provided, or the first focusable element otherwise. - */ - applyFocus(): void; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired after the component is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired after the component is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired after the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired after the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Popover$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Popover$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Popover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Popover` itself. - * - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Popover` itself - */ - oListener?: object - ): this; - /** - * Closes the popup. - */ - close(): void; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys all the footer in the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyFooter(): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.Popover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.Popover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.Popover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Popover$BeforeCloseEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.Popover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:afterClose afterClose} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterClose( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:afterOpen afterOpen} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:beforeClose beforeClose} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeClose( - /** - * Parameters to pass along with the event - */ - mParameters?: Popover$BeforeCloseEventParameters - ): boolean; - /** - * Fires event {@link #event:beforeOpen beforeOpen} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): boolean; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAccessibleRole accessibleRole}. - * - * Allows setting a custom role. - * - * Default value is `Dialog`. - * - * - * @returns Value of property `accessibleRole` - */ - getAccessibleRole(): PopupAccessibleRole; - /** - * Gets current value of property {@link #getAllowTargetOverlap allowTargetOverlap}. - * - * Determines if there is no enough space, the component can be placed over the target. - * - * Default value is `false`. - * - * - * @returns Value of property `allowTargetOverlap` - */ - getAllowTargetOverlap(): boolean; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the Popup. - */ - getContent(): Control[]; - /** - * Gets content of aggregation {@link #getFooter footer}. - * - * Defines the footer HTML Element. - */ - getFooter(): Control[]; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the header HTML Element. - */ - getHeader(): Control[]; - /** - * Gets current value of property {@link #getHeaderText headerText}. - * - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - * - * Default value is `empty string`. - * - * - * @returns Value of property `headerText` - */ - getHeaderText(): string; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getHideArrow hideArrow}. - * - * Determines whether the component arrow is hidden. - * - * Default value is `false`. - * - * - * @returns Value of property `hideArrow` - */ - getHideArrow(): boolean; - /** - * Gets current value of property {@link #getHideBackdrop hideBackdrop}. - * - * Defines whether the block layer will be shown if modal property is set to true. - * - * Default value is `false`. - * - * - * @returns Value of property `hideBackdrop` - */ - getHideBackdrop(): boolean; - /** - * Gets current value of property {@link #getHorizontalAlign horizontalAlign}. - * - * Determines the horizontal alignment of the component. - * - * Default value is `Center`. - * - * - * @returns Value of property `horizontalAlign` - */ - getHorizontalAlign(): PopoverHorizontalAlign; - /** - * ID of the element which is the current target of the association {@link #getInitialFocus initialFocus}, - * or `null`. - */ - getInitialFocus(): ID | null; - /** - * Gets current value of property {@link #getModal modal}. - * - * Defines whether the component should close when clicking/tapping outside of the popover. If enabled, - * it blocks any interaction with the background. - * - * Default value is `false`. - * - * - * @returns Value of property `modal` - */ - getModal(): boolean; - /** - * Gets current value of property {@link #getOpen open}. - * - * Indicates if the element is open - * - * Default value is `false`. - * - * - * @returns Value of property `open` - */ - getOpen(): boolean; - /** - * ID of the element which is the current target of the association {@link #getOpener opener}, or `null`. - */ - getOpener(): ID | null; - /** - * Gets current value of property {@link #getPlacementType placementType}. - * - * Determines on which side the component is placed at. - * - * Default value is `Right`. - * - * - * @returns Value of property `placementType` - */ - getPlacementType(): PopoverPlacementType; - /** - * Gets current value of property {@link #getPreventFocusRestore preventFocusRestore}. - * - * Defines if the focus should be returned to the previously focused element, when the popup closes. - * - * Default value is `false`. - * - * - * @returns Value of property `preventFocusRestore` - */ - getPreventFocusRestore(): boolean; - /** - * Gets current value of property {@link #getVerticalAlign verticalAlign}. - * - * Determines the vertical alignment of the component. - * - * Default value is `Center`. - * - * - * @returns Value of property `verticalAlign` - */ - getVerticalAlign(): PopoverVerticalAlign; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getFooter footer}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfFooter( - /** - * The footer whose index is looked for - */ - oFooter: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a footer into the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertFooter( - /** - * The footer to insert; if empty, nothing is inserted - */ - oFooter: Control, - /** - * The `0`-based index the footer should be inserted at; for a negative value of `iIndex`, the footer is - * inserted at position 0; for a value greater than the current size of the aggregation, the footer is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Tells if the component is opened - */ - isOpen(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getFooter footer}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllFooter(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a footer from the aggregation {@link #getFooter footer}. - * - * - * @returns The removed footer or `null` - */ - removeFooter( - /** - * The footer to remove or its index or id - */ - vFooter: int | string | Control - ): Control | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAccessibleRole accessibleRole}. - * - * Allows setting a custom role. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Dialog`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleRole( - /** - * New value for property `accessibleRole` - */ - sAccessibleRole?: PopupAccessibleRole | keyof typeof PopupAccessibleRole - ): this; - /** - * Sets a new value for property {@link #getAllowTargetOverlap allowTargetOverlap}. - * - * Determines if there is no enough space, the component can be placed over the target. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAllowTargetOverlap( - /** - * New value for property `allowTargetOverlap` - */ - bAllowTargetOverlap?: boolean - ): this; - /** - * Sets a new value for property {@link #getHeaderText headerText}. - * - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderText( - /** - * New value for property `headerText` - */ - sHeaderText?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getHideArrow hideArrow}. - * - * Determines whether the component arrow is hidden. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideArrow( - /** - * New value for property `hideArrow` - */ - bHideArrow?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideBackdrop hideBackdrop}. - * - * Defines whether the block layer will be shown if modal property is set to true. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideBackdrop( - /** - * New value for property `hideBackdrop` - */ - bHideBackdrop?: boolean - ): this; - /** - * Sets a new value for property {@link #getHorizontalAlign horizontalAlign}. - * - * Determines the horizontal alignment of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Center`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHorizontalAlign( - /** - * New value for property `horizontalAlign` - */ - sHorizontalAlign?: - | PopoverHorizontalAlign - | keyof typeof PopoverHorizontalAlign - ): this; - /** - * Sets the associated {@link #getInitialFocus initialFocus}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInitialFocus( - /** - * ID of an element which becomes the new target of this initialFocus association; alternatively, an element - * instance may be given - */ - oInitialFocus: ID | Control - ): this; - /** - * Sets a new value for property {@link #getModal modal}. - * - * Defines whether the component should close when clicking/tapping outside of the popover. If enabled, - * it blocks any interaction with the background. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setModal( - /** - * New value for property `modal` - */ - bModal?: boolean - ): this; - /** - * Sets a new value for property {@link #getOpen open}. - * - * Indicates if the element is open - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOpen( - /** - * New value for property `open` - */ - bOpen?: boolean - ): this; - /** - * Sets the associated {@link #getOpener opener}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOpener( - /** - * ID of an element which becomes the new target of this opener association; alternatively, an element instance - * may be given - */ - oOpener: ID | Control - ): this; - /** - * Sets a new value for property {@link #getPlacementType placementType}. - * - * Determines on which side the component is placed at. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Right`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlacementType( - /** - * New value for property `placementType` - */ - sPlacementType?: PopoverPlacementType | keyof typeof PopoverPlacementType - ): this; - /** - * Sets a new value for property {@link #getPreventFocusRestore preventFocusRestore}. - * - * Defines if the focus should be returned to the previously focused element, when the popup closes. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPreventFocusRestore( - /** - * New value for property `preventFocusRestore` - */ - bPreventFocusRestore?: boolean - ): this; - /** - * Sets a new value for property {@link #getVerticalAlign verticalAlign}. - * - * Determines the vertical alignment of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Center`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setVerticalAlign( - /** - * New value for property `verticalAlign` - */ - sVerticalAlign?: PopoverVerticalAlign | keyof typeof PopoverVerticalAlign - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Shows the popover. - */ - showAt( - /** - * the element that the popover is shown at - */ - opener: HTMLElement, - /** - * prevents applying the focus inside the popover - */ - preventInitialFocus: boolean - ): void; - } - /** - * Describes the settings that can be provided to the Popover constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $PopoverSettings extends $WebComponentSettings { - /** - * Defines the accessible name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Allows setting a custom role. - */ - accessibleRole?: - | (PopupAccessibleRole | keyof typeof PopupAccessibleRole) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines if there is no enough space, the component can be placed over the target. - */ - allowTargetOverlap?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - */ - headerText?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Determines whether the component arrow is hidden. - */ - hideArrow?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the block layer will be shown if modal property is set to true. - */ - hideBackdrop?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the horizontal alignment of the component. - */ - horizontalAlign?: - | (PopoverHorizontalAlign | keyof typeof PopoverHorizontalAlign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the component should close when clicking/tapping outside of the popover. If enabled, - * it blocks any interaction with the background. - */ - modal?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Indicates if the element is open - */ - open?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines on which side the component is placed at. - */ - placementType?: - | (PopoverPlacementType | keyof typeof PopoverPlacementType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines if the focus should be returned to the previously focused element, when the popup closes. - */ - preventFocusRestore?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the vertical alignment of the component. - */ - verticalAlign?: - | (PopoverVerticalAlign | keyof typeof PopoverVerticalAlign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the Popup. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the footer HTML Element. - */ - footer?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the header HTML Element. - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the ID or DOM Reference of the element that the popover is shown at - */ - opener?: Control | string; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Defines the ID of the HTML Element, which will get the initial focus. - */ - initialFocus?: Control | string; - - /** - * Fired after the component is closed. **This event does not bubble.** - */ - afterClose?: (oEvent: Event) => void; - - /** - * Fired after the component is opened. **This event does not bubble.** - */ - afterOpen?: (oEvent: Event) => void; - - /** - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - */ - beforeClose?: (oEvent: Popover$BeforeCloseEvent) => void; - - /** - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - */ - beforeOpen?: (oEvent: Event) => void; - } - - /** - * Parameters of the Popover#afterClose event. - */ - export interface Popover$AfterCloseEventParameters {} - - /** - * Event object of the Popover#afterClose event. - */ - export type Popover$AfterCloseEvent = Event< - Popover$AfterCloseEventParameters, - Popover - >; - - /** - * Parameters of the Popover#afterOpen event. - */ - export interface Popover$AfterOpenEventParameters {} - - /** - * Event object of the Popover#afterOpen event. - */ - export type Popover$AfterOpenEvent = Event< - Popover$AfterOpenEventParameters, - Popover - >; - - /** - * Parameters of the Popover#beforeClose event. - */ - export interface Popover$BeforeCloseEventParameters { - /** - * Indicates that `ESC` key has triggered the event. - */ - escPressed?: boolean; - } - - /** - * Event object of the Popover#beforeClose event. - */ - export type Popover$BeforeCloseEvent = Event< - Popover$BeforeCloseEventParameters, - Popover - >; - - /** - * Parameters of the Popover#beforeOpen event. - */ - export interface Popover$BeforeOpenEventParameters {} - - /** - * Event object of the Popover#beforeOpen event. - */ - export type Popover$BeforeOpenEvent = Event< - Popover$BeforeOpenEventParameters, - Popover - >; -} - -declare module "sap/ui/webc/main/ProgressIndicator" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ValueState, CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: Shows the progress of a process in a graphical way. To indicate the progress, the inside of - * the component is filled with a color. - * - * Responsive Behavior: You can change the size of the Progress Indicator by changing its `width` or `height` - * CSS properties. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ProgressIndicator - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `ProgressIndicator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ProgressIndicatorSettings - ); - /** - * Constructor for a new `ProgressIndicator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ProgressIndicatorSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ProgressIndicator with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ProgressIndicator. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getDisplayValue displayValue}. - * - * Specifies the text value to be displayed in the bar. - * - * **Note:** - * - If there is no value provided or the value is empty, the default percentage value is shown. - * - If `hideValue` property is `true` both the `displayValue` and `value` property values are not shown. - * - * - * - * @returns Value of property `displayValue` - */ - getDisplayValue(): string; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getHideValue hideValue}. - * - * Defines whether the component value is shown. - * - * Default value is `false`. - * - * - * @returns Value of property `hideValue` - */ - getHideValue(): boolean; - /** - * Gets current value of property {@link #getValue value}. - * - * Specifies the numerical value in percent for the length of the component. - * - * **Note:** If a value greater than 100 is provided, the percentValue is set to 100. In other cases of - * invalid value, percentValue is set to its default of 0. - * - * Default value is `0`. - * - * - * @returns Value of property `value` - */ - getValue(): int; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getDisplayValue displayValue}. - * - * Specifies the text value to be displayed in the bar. - * - * **Note:** - * - If there is no value provided or the value is empty, the default percentage value is shown. - * - If `hideValue` property is `true` both the `displayValue` and `value` property values are not shown. - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDisplayValue( - /** - * New value for property `displayValue` - */ - sDisplayValue: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideValue hideValue}. - * - * Defines whether the component value is shown. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideValue( - /** - * New value for property `hideValue` - */ - bHideValue?: boolean - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Specifies the numerical value in percent for the length of the component. - * - * **Note:** If a value greater than 100 is provided, the percentValue is set to 100. In other cases of - * invalid value, percentValue is set to its default of 0. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - iValue?: int - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the ProgressIndicator constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ProgressIndicatorSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Specifies the text value to be displayed in the bar. - * - * **Note:** - * - If there is no value provided or the value is empty, the default percentage value is shown. - * - If `hideValue` property is `true` both the `displayValue` and `value` property values are not shown. - */ - displayValue?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component value is shown. - */ - hideValue?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Specifies the numerical value in percent for the length of the component. - * - * **Note:** If a value greater than 100 is provided, the percentValue is set to 100. In other cases of - * invalid value, percentValue is set to its default of 0. - */ - value?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the value state of the component. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/RadioButton" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { WrappingType } from "sap/ui/webc/main/library"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.RadioButton` component enables users to select a single option from a set of options. - * When a `sap.ui.webc.main.RadioButton` is selected by the user, the `change` event is fired. When a `sap.ui.webc.main.RadioButton` - * that is within a group is selected, the one that was previously selected gets automatically deselected. - * You can group radio buttons by using the `name` property. - * **Note:** If `sap.ui.webc.main.RadioButton` is not part of a group, it can be selected once, but can - * not be deselected back. - * - * Keyboard Handling: - * - * Once the `sap.ui.webc.main.RadioButton` is on focus, it might be selected by pressing the Space and Enter - * keys. - * The Arrow Down/Arrow Up and Arrow Left/Arrow Right keys can be used to change selection between next/previous - * radio buttons in one group, while TAB and SHIFT + TAB can be used to enter or leave the radio button - * group. - * **Note:** On entering radio button group, the focus goes to the currently selected radio button. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class RadioButton - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `RadioButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $RadioButtonSettings - ); - /** - * Constructor for a new `RadioButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $RadioButtonSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.RadioButton with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.RadioButton. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.RadioButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RadioButton` itself. - * - * Fired when the component checked state changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RadioButton` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.RadioButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RadioButton` itself. - * - * Fired when the component checked state changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RadioButton` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.RadioButton`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getChecked checked}. - * - * Defines whether the component is checked or not. - * - * **Note:** The property value can be changed with user interaction, either by clicking/tapping on the - * component, or by using the Space or Enter key. - * - * Default value is `false`. - * - * - * @returns Value of property `checked` - */ - getChecked(): boolean; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getName name}. - * - * Defines the name of the component. Radio buttons with the same `name` will form a radio button group. - * - * - * - * **Note:** The selection can be changed with `ARROW_UP/DOWN` and `ARROW_LEFT/RIGHT` keys between radio - * buttons in same group. - * - * - * - * **Note:** Only one radio button can be selected per group. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getValue value}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Gets current value of property {@link #getWrappingType wrappingType}. - * - * Defines whether the component text wraps when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * Default value is `None`. - * - * - * @returns Value of property `wrappingType` - */ - getWrappingType(): WrappingType; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getChecked checked}. - * - * Defines whether the component is checked or not. - * - * **Note:** The property value can be changed with user interaction, either by clicking/tapping on the - * component, or by using the Space or Enter key. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setChecked( - /** - * New value for property `checked` - */ - bChecked?: boolean - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Defines the name of the component. Radio buttons with the same `name` will form a radio button group. - * - * - * - * **Note:** The selection can be changed with `ARROW_UP/DOWN` and `ARROW_LEFT/RIGHT` keys between radio - * buttons in same group. - * - * - * - * **Note:** Only one radio button can be selected per group. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Sets a new value for property {@link #getWrappingType wrappingType}. - * - * Defines whether the component text wraps when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWrappingType( - /** - * New value for property `wrappingType` - */ - sWrappingType?: WrappingType | keyof typeof WrappingType - ): this; - } - /** - * Describes the settings that can be provided to the RadioButton constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $RadioButtonSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the component is checked or not. - * - * **Note:** The property value can be changed with user interaction, either by clicking/tapping on the - * component, or by using the Space or Enter key. - */ - checked?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the name of the component. Radio buttons with the same `name` will form a radio button group. - * - * - * - * **Note:** The selection can be changed with `ARROW_UP/DOWN` and `ARROW_LEFT/RIGHT` keys between radio - * buttons in same group. - * - * - * - * **Note:** Only one radio button can be selected per group. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component text wraps when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - */ - wrappingType?: - | (WrappingType | keyof typeof WrappingType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component checked state changes. - */ - change?: (oEvent: Event) => void; - } - - /** - * Parameters of the RadioButton#change event. - */ - export interface RadioButton$ChangeEventParameters {} - - /** - * Event object of the RadioButton#change event. - */ - export type RadioButton$ChangeEvent = Event< - RadioButton$ChangeEventParameters, - RadioButton - >; -} - -declare module "sap/ui/webc/main/RangeSlider" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { CSSSize } from "sap/ui/core/library"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: Represents a numerical interval and two handles (grips) to select a sub-range within it. The - * purpose of the component to enable visual selection of sub-ranges within a given interval. - * - * Structure: The most important properties of the Range Slider are: - * - min - The minimum value of the slider range. - * - max - The maximum value of the slider range. - * - value - The current value of the slider. - * - step - Determines the increments in which the slider will move. - * - showTooltip - Determines if a tooltip should be displayed above the handle. - * - showTickmarks - Displays a visual divider between the step values. - * - labelInterval - Labels some or all of the tickmarks with their values. Notes:: - * - The right and left handle can be moved individually and their positions could therefore switch. - * - The entire range can be moved along the interval. Usage: The most common use case is to select - * and move sub-ranges on a continuous numerical scale. - * - * Responsive Behavior: You can move the currently selected range by clicking on it and dragging it along - * the interval. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.RangeSlider` exposes the following CSS Shadow Parts: - * - progress-container - Used to style the progress container(the horizontal bar which visually represents - * the range between the minimum and maximum value) of the `sap.ui.webc.main.RangeSlider`. - * - progress-bar - Used to style the progress bar, which shows the progress of the `sap.ui.webc.main.RangeSlider`. - * - * - handle - Used to style the handles of the `sap.ui.webc.main.RangeSlider`. - * - * Keyboard Handling: - * - * - * - `Left or Down Arrow` - Moves a component's handle or the entire selection one step to the left; - * - `Right or Up Arrow` - Moves a component's handle or the entire selection one step to the right; - * - `Left or Down Arrow + Ctrl/Cmd` - Moves a component's handle to the left or the entire range with - * step equal to 1/10th of the entire range; - * - `Right or Up Arrow + Ctrl/Cmd` - Moves a component's handle to the right or the entire range with - * step equal to 1/10th of the entire range; - * - `Plus` - Same as `Right or Up Arrow`; - * - `Minus` - Same as `Left or Down Arrow`; - * - `Home` - Moves the entire selection or the selected handle to the beginning of the component's range; - * - * - `End` - Moves the entire selection or the selected handle to the end of the component's range; - * - `Page Up` - Same as `Right or Up Arrow + Ctrl/Cmd`; - * - `Page Down` - Same as `Left or Down Arrow + Ctrl/Cmd`; - * - `Escape` - Resets the `startValue` and `endValue` properties to the values prior the component focusing; - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class RangeSlider extends WebComponent { - /** - * Constructor for a new `RangeSlider`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $RangeSliderSettings - ); - /** - * Constructor for a new `RangeSlider`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $RangeSliderSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.RangeSlider with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.RangeSlider. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.RangeSlider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RangeSlider` itself. - * - * Fired when the value changes and the user has finished interacting with the slider. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RangeSlider` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.RangeSlider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RangeSlider` itself. - * - * Fired when the value changes and the user has finished interacting with the slider. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RangeSlider` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.RangeSlider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RangeSlider` itself. - * - * Fired when the value changes due to user interaction that is not yet finished - during mouse/touch dragging. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RangeSlider` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.RangeSlider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RangeSlider` itself. - * - * Fired when the value changes due to user interaction that is not yet finished - during mouse/touch dragging. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RangeSlider` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.RangeSlider`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.RangeSlider`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getEndValue endValue}. - * - * Defines end point of a selection - position of a second handle on the slider. - * - * - * - * Default value is `100`. - * - * - * @returns Value of property `endValue` - */ - getEndValue(): float; - /** - * Gets current value of property {@link #getLabelInterval labelInterval}. - * - * Displays a label with a value on every N-th step. - * - * **Note:** The step and tickmarks properties must be enabled. Example - if the step value is set to 2 - * and the label interval is also specified to 2 - then every second tickmark will be labelled, which means - * every 4th value number. - * - * Default value is `0`. - * - * - * @returns Value of property `labelInterval` - */ - getLabelInterval(): int; - /** - * Gets current value of property {@link #getMax max}. - * - * Defines the maximum value of the slider. - * - * Default value is `100`. - * - * - * @returns Value of property `max` - */ - getMax(): float; - /** - * Gets current value of property {@link #getMin min}. - * - * Defines the minimum value of the slider. - * - * Default value is `0`. - * - * - * @returns Value of property `min` - */ - getMin(): float; - /** - * Gets current value of property {@link #getShowTickmarks showTickmarks}. - * - * Enables tickmarks visualization for each step. - * - * **Note:** The step must be a positive number. - * - * Default value is `false`. - * - * - * @returns Value of property `showTickmarks` - */ - getShowTickmarks(): boolean; - /** - * Gets current value of property {@link #getShowTooltip showTooltip}. - * - * Enables handle tooltip displaying the current value. - * - * Default value is `false`. - * - * - * @returns Value of property `showTooltip` - */ - getShowTooltip(): boolean; - /** - * Gets current value of property {@link #getStartValue startValue}. - * - * Defines start point of a selection - position of a first handle on the slider. - * - * - * - * Default value is `0`. - * - * - * @returns Value of property `startValue` - */ - getStartValue(): float; - /** - * Gets current value of property {@link #getStep step}. - * - * Defines the size of the slider's selection intervals (e.g. min = 0, max = 10, step = 5 would result in - * possible selection of the values 0, 5, 10). - * - * **Note:** If set to 0 the slider handle movement is disabled. When negative number or value other than - * a number, the component fallbacks to its default value. - * - * Default value is `1`. - * - * - * @returns Value of property `step` - */ - getStep(): int; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getEndValue endValue}. - * - * Defines end point of a selection - position of a second handle on the slider. - * - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `100`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEndValue( - /** - * New value for property `endValue` - */ - fEndValue?: float - ): this; - /** - * Sets a new value for property {@link #getLabelInterval labelInterval}. - * - * Displays a label with a value on every N-th step. - * - * **Note:** The step and tickmarks properties must be enabled. Example - if the step value is set to 2 - * and the label interval is also specified to 2 - then every second tickmark will be labelled, which means - * every 4th value number. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLabelInterval( - /** - * New value for property `labelInterval` - */ - iLabelInterval?: int - ): this; - /** - * Sets a new value for property {@link #getMax max}. - * - * Defines the maximum value of the slider. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `100`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMax( - /** - * New value for property `max` - */ - fMax?: float - ): this; - /** - * Sets a new value for property {@link #getMin min}. - * - * Defines the minimum value of the slider. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMin( - /** - * New value for property `min` - */ - fMin?: float - ): this; - /** - * Sets a new value for property {@link #getShowTickmarks showTickmarks}. - * - * Enables tickmarks visualization for each step. - * - * **Note:** The step must be a positive number. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowTickmarks( - /** - * New value for property `showTickmarks` - */ - bShowTickmarks?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowTooltip showTooltip}. - * - * Enables handle tooltip displaying the current value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowTooltip( - /** - * New value for property `showTooltip` - */ - bShowTooltip?: boolean - ): this; - /** - * Sets a new value for property {@link #getStartValue startValue}. - * - * Defines start point of a selection - position of a first handle on the slider. - * - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStartValue( - /** - * New value for property `startValue` - */ - fStartValue?: float - ): this; - /** - * Sets a new value for property {@link #getStep step}. - * - * Defines the size of the slider's selection intervals (e.g. min = 0, max = 10, step = 5 would result in - * possible selection of the values 0, 5, 10). - * - * **Note:** If set to 0 the slider handle movement is disabled. When negative number or value other than - * a number, the component fallbacks to its default value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStep( - /** - * New value for property `step` - */ - iStep?: int - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the RangeSlider constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $RangeSliderSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines end point of a selection - position of a second handle on the slider. - */ - endValue?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Displays a label with a value on every N-th step. - * - * **Note:** The step and tickmarks properties must be enabled. Example - if the step value is set to 2 - * and the label interval is also specified to 2 - then every second tickmark will be labelled, which means - * every 4th value number. - */ - labelInterval?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the maximum value of the slider. - */ - max?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the minimum value of the slider. - */ - min?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Enables tickmarks visualization for each step. - * - * **Note:** The step must be a positive number. - */ - showTickmarks?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Enables handle tooltip displaying the current value. - */ - showTooltip?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines start point of a selection - position of a first handle on the slider. - */ - startValue?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the size of the slider's selection intervals (e.g. min = 0, max = 10, step = 5 would result in - * possible selection of the values 0, 5, 10). - * - * **Note:** If set to 0 the slider handle movement is disabled. When negative number or value other than - * a number, the component fallbacks to its default value. - */ - step?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Fired when the value changes and the user has finished interacting with the slider. - */ - change?: (oEvent: Event) => void; - - /** - * Fired when the value changes due to user interaction that is not yet finished - during mouse/touch dragging. - */ - input?: (oEvent: Event) => void; - } - - /** - * Parameters of the RangeSlider#change event. - */ - export interface RangeSlider$ChangeEventParameters {} - - /** - * Event object of the RangeSlider#change event. - */ - export type RangeSlider$ChangeEvent = Event< - RangeSlider$ChangeEventParameters, - RangeSlider - >; - - /** - * Parameters of the RangeSlider#input event. - */ - export interface RangeSlider$InputEventParameters {} - - /** - * Event object of the RangeSlider#input event. - */ - export type RangeSlider$InputEvent = Event< - RangeSlider$InputEventParameters, - RangeSlider - >; -} - -declare module "sap/ui/webc/main/RatingIndicator" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The Rating Indicator is used to display a specific number of icons that are used to rate an - * item. Additionally, it is also used to display the average and overall ratings. - * - * Usage: The recommended number of icons is between 5 and 7. - * - * Responsive Behavior: You can change the size of the Rating Indicator by changing its `font-size` CSS - * property. - * Example: `` - * - * Keyboard Handling: When the `sap.ui.webc.main.RatingIndicator` is focused, the user can change the rating - * with the following keyboard shortcuts: - * - * - * - * - [RIGHT/UP] - Increases the value of the rating by one step. If the highest value is reached, does - * nothing - * - [LEFT/DOWN] - Decreases the value of the rating by one step. If the lowest value is reached, does - * nothing. - * - [HOME] - Sets the lowest value. - * - [END] - Sets the highest value. - * - [SPACE/ENTER/RETURN] - Increases the value of the rating by one step. If the highest value is reached, - * sets the rating to the lowest value. - * - Any number - Changes value to the corresponding number. If typed number is larger than the number - * of values, sets the highest value. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class RatingIndicator - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `RatingIndicator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $RatingIndicatorSettings - ); - /** - * Constructor for a new `RatingIndicator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $RatingIndicatorSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.RatingIndicator with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.RatingIndicator. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.RatingIndicator`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RatingIndicator` itself. - * - * The event is fired when the value changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RatingIndicator` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.RatingIndicator`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.RatingIndicator` itself. - * - * The event is fired when the value changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.RatingIndicator` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.RatingIndicator`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getMax max}. - * - * The number of displayed rating symbols. - * - * Default value is `5`. - * - * - * @returns Value of property `max` - */ - getMax(): int; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getValue value}. - * - * The indicated value of the rating. - * - * **Note:** If you set a number which is not round, it would be shown as follows: - * - 1.0 - 1.2 -> 1 - * - 1.3 - 1.7 -> 1.5 - * - 1.8 - 1.9 -> 2 - * - * Default value is `0`. - * - * - * @returns Value of property `value` - */ - getValue(): float; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getMax max}. - * - * The number of displayed rating symbols. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `5`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMax( - /** - * New value for property `max` - */ - iMax?: int - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * The indicated value of the rating. - * - * **Note:** If you set a number which is not round, it would be shown as follows: - * - 1.0 - 1.2 -> 1 - * - 1.3 - 1.7 -> 1.5 - * - 1.8 - 1.9 -> 2 - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - fValue?: float - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the RatingIndicator constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $RatingIndicatorSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * The number of displayed rating symbols. - */ - max?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * The indicated value of the rating. - * - * **Note:** If you set a number which is not round, it would be shown as follows: - * - 1.0 - 1.2 -> 1 - * - 1.3 - 1.7 -> 1.5 - * - 1.8 - 1.9 -> 2 - */ - value?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * The event is fired when the value changes. - */ - change?: (oEvent: Event) => void; - } - - /** - * Parameters of the RatingIndicator#change event. - */ - export interface RatingIndicator$ChangeEventParameters {} - - /** - * Event object of the RatingIndicator#change event. - */ - export type RatingIndicator$ChangeEvent = Event< - RatingIndicator$ChangeEventParameters, - RatingIndicator - >; -} - -declare module "sap/ui/webc/main/ResponsivePopover" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { - PopupAccessibleRole, - PopoverHorizontalAlign, - PopoverPlacementType, - PopoverVerticalAlign, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.ResponsivePopover` acts as a Popover on desktop and tablet, while on - * phone it acts as a Dialog. The component improves tremendously the user experience on mobile. - * - * Usage: Use it when you want to make sure that all the content is visible on any device. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.ResponsivePopover` exposes the following CSS Shadow Parts: - * - header - Used to style the header of the component - * - content - Used to style the content of the component - * - footer - Used to style the footer of the component - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ResponsivePopover extends WebComponent { - /** - * Constructor for a new `ResponsivePopover`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ResponsivePopoverSettings - ); - /** - * Constructor for a new `ResponsivePopover`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ResponsivePopoverSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ResponsivePopover with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ResponsivePopover. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some footer to the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addFooter( - /** - * The footer to add; if empty, nothing is inserted - */ - oFooter: Control - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Focuses the element denoted by `initialFocus`, if provided, or the first focusable element otherwise. - */ - applyFocus(): void; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired after the component is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired after the component is closed. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired after the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired after the component is opened. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachAfterOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ResponsivePopover$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ResponsivePopover$BeforeCloseEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ResponsivePopover` itself. - * - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachBeforeOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ResponsivePopover` - * itself - */ - oListener?: object - ): this; - /** - * Closes the popover/dialog. - */ - close(): void; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys all the footer in the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyFooter(): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterClose afterClose} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:afterOpen afterOpen} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachAfterOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeClose beforeClose} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ResponsivePopover$BeforeCloseEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:beforeOpen beforeOpen} event of this `sap.ui.webc.main.ResponsivePopover`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachBeforeOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:afterClose afterClose} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterClose( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:afterOpen afterOpen} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireAfterOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:beforeClose beforeClose} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeClose( - /** - * Parameters to pass along with the event - */ - mParameters?: ResponsivePopover$BeforeCloseEventParameters - ): boolean; - /** - * Fires event {@link #event:beforeOpen beforeOpen} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireBeforeOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): boolean; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAccessibleRole accessibleRole}. - * - * Allows setting a custom role. - * - * Default value is `Dialog`. - * - * - * @returns Value of property `accessibleRole` - */ - getAccessibleRole(): PopupAccessibleRole; - /** - * Gets current value of property {@link #getAllowTargetOverlap allowTargetOverlap}. - * - * Determines if there is no enough space, the component can be placed over the target. - * - * Default value is `false`. - * - * - * @returns Value of property `allowTargetOverlap` - */ - getAllowTargetOverlap(): boolean; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the Popup. - */ - getContent(): Control[]; - /** - * Gets content of aggregation {@link #getFooter footer}. - * - * Defines the footer HTML Element. - */ - getFooter(): Control[]; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the header HTML Element. - */ - getHeader(): Control[]; - /** - * Gets current value of property {@link #getHeaderText headerText}. - * - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - * - * Default value is `empty string`. - * - * - * @returns Value of property `headerText` - */ - getHeaderText(): string; - /** - * Gets current value of property {@link #getHideArrow hideArrow}. - * - * Determines whether the component arrow is hidden. - * - * Default value is `false`. - * - * - * @returns Value of property `hideArrow` - */ - getHideArrow(): boolean; - /** - * Gets current value of property {@link #getHideBackdrop hideBackdrop}. - * - * Defines whether the block layer will be shown if modal property is set to true. - * - * Default value is `false`. - * - * - * @returns Value of property `hideBackdrop` - */ - getHideBackdrop(): boolean; - /** - * Gets current value of property {@link #getHorizontalAlign horizontalAlign}. - * - * Determines the horizontal alignment of the component. - * - * Default value is `Center`. - * - * - * @returns Value of property `horizontalAlign` - */ - getHorizontalAlign(): PopoverHorizontalAlign; - /** - * ID of the element which is the current target of the association {@link #getInitialFocus initialFocus}, - * or `null`. - */ - getInitialFocus(): ID | null; - /** - * Gets current value of property {@link #getModal modal}. - * - * Defines whether the component should close when clicking/tapping outside of the popover. If enabled, - * it blocks any interaction with the background. - * - * Default value is `false`. - * - * - * @returns Value of property `modal` - */ - getModal(): boolean; - /** - * Gets current value of property {@link #getOpen open}. - * - * Indicates if the element is open - * - * Default value is `false`. - * - * - * @returns Value of property `open` - */ - getOpen(): boolean; - /** - * ID of the element which is the current target of the association {@link #getOpener opener}, or `null`. - */ - getOpener(): ID | null; - /** - * Gets current value of property {@link #getPlacementType placementType}. - * - * Determines on which side the component is placed at. - * - * Default value is `Right`. - * - * - * @returns Value of property `placementType` - */ - getPlacementType(): PopoverPlacementType; - /** - * Gets current value of property {@link #getPreventFocusRestore preventFocusRestore}. - * - * Defines if the focus should be returned to the previously focused element, when the popup closes. - * - * Default value is `false`. - * - * - * @returns Value of property `preventFocusRestore` - */ - getPreventFocusRestore(): boolean; - /** - * Gets current value of property {@link #getVerticalAlign verticalAlign}. - * - * Determines the vertical alignment of the component. - * - * Default value is `Center`. - * - * - * @returns Value of property `verticalAlign` - */ - getVerticalAlign(): PopoverVerticalAlign; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getFooter footer}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfFooter( - /** - * The footer whose index is looked for - */ - oFooter: Control - ): int; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a footer into the aggregation {@link #getFooter footer}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertFooter( - /** - * The footer to insert; if empty, nothing is inserted - */ - oFooter: Control, - /** - * The `0`-based index the footer should be inserted at; for a negative value of `iIndex`, the footer is - * inserted at position 0; for a value greater than the current size of the aggregation, the footer is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Tells if the responsive popover is open. - */ - isOpen(): void; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getFooter footer}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllFooter(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a footer from the aggregation {@link #getFooter footer}. - * - * - * @returns The removed footer or `null` - */ - removeFooter( - /** - * The footer to remove or its index or id - */ - vFooter: int | string | Control - ): Control | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAccessibleRole accessibleRole}. - * - * Allows setting a custom role. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Dialog`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleRole( - /** - * New value for property `accessibleRole` - */ - sAccessibleRole?: PopupAccessibleRole | keyof typeof PopupAccessibleRole - ): this; - /** - * Sets a new value for property {@link #getAllowTargetOverlap allowTargetOverlap}. - * - * Determines if there is no enough space, the component can be placed over the target. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAllowTargetOverlap( - /** - * New value for property `allowTargetOverlap` - */ - bAllowTargetOverlap?: boolean - ): this; - /** - * Sets a new value for property {@link #getHeaderText headerText}. - * - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderText( - /** - * New value for property `headerText` - */ - sHeaderText?: string - ): this; - /** - * Sets a new value for property {@link #getHideArrow hideArrow}. - * - * Determines whether the component arrow is hidden. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideArrow( - /** - * New value for property `hideArrow` - */ - bHideArrow?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideBackdrop hideBackdrop}. - * - * Defines whether the block layer will be shown if modal property is set to true. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideBackdrop( - /** - * New value for property `hideBackdrop` - */ - bHideBackdrop?: boolean - ): this; - /** - * Sets a new value for property {@link #getHorizontalAlign horizontalAlign}. - * - * Determines the horizontal alignment of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Center`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHorizontalAlign( - /** - * New value for property `horizontalAlign` - */ - sHorizontalAlign?: - | PopoverHorizontalAlign - | keyof typeof PopoverHorizontalAlign - ): this; - /** - * Sets the associated {@link #getInitialFocus initialFocus}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setInitialFocus( - /** - * ID of an element which becomes the new target of this initialFocus association; alternatively, an element - * instance may be given - */ - oInitialFocus: ID | Control - ): this; - /** - * Sets a new value for property {@link #getModal modal}. - * - * Defines whether the component should close when clicking/tapping outside of the popover. If enabled, - * it blocks any interaction with the background. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setModal( - /** - * New value for property `modal` - */ - bModal?: boolean - ): this; - /** - * Sets a new value for property {@link #getOpen open}. - * - * Indicates if the element is open - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOpen( - /** - * New value for property `open` - */ - bOpen?: boolean - ): this; - /** - * Sets the associated {@link #getOpener opener}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOpener( - /** - * ID of an element which becomes the new target of this opener association; alternatively, an element instance - * may be given - */ - oOpener: ID | Control - ): this; - /** - * Sets a new value for property {@link #getPlacementType placementType}. - * - * Determines on which side the component is placed at. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Right`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlacementType( - /** - * New value for property `placementType` - */ - sPlacementType?: PopoverPlacementType | keyof typeof PopoverPlacementType - ): this; - /** - * Sets a new value for property {@link #getPreventFocusRestore preventFocusRestore}. - * - * Defines if the focus should be returned to the previously focused element, when the popup closes. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPreventFocusRestore( - /** - * New value for property `preventFocusRestore` - */ - bPreventFocusRestore?: boolean - ): this; - /** - * Sets a new value for property {@link #getVerticalAlign verticalAlign}. - * - * Determines the vertical alignment of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Center`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setVerticalAlign( - /** - * New value for property `verticalAlign` - */ - sVerticalAlign?: PopoverVerticalAlign | keyof typeof PopoverVerticalAlign - ): this; - /** - * Shows popover on desktop and dialog on mobile. - */ - showAt( - /** - * the element that the popover is shown at - */ - opener: HTMLElement, - /** - * Prevents applying the focus inside the popup - */ - preventInitialFocus: boolean - ): void; - } - /** - * Describes the settings that can be provided to the ResponsivePopover constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ResponsivePopoverSettings extends $WebComponentSettings { - /** - * Defines the accessible name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Allows setting a custom role. - */ - accessibleRole?: - | (PopupAccessibleRole | keyof typeof PopupAccessibleRole) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Determines if there is no enough space, the component can be placed over the target. - */ - allowTargetOverlap?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the header text. - * - * **Note:** If `header` slot is provided, the `headerText` is ignored. - */ - headerText?: string | PropertyBindingInfo; - - /** - * Determines whether the component arrow is hidden. - */ - hideArrow?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the block layer will be shown if modal property is set to true. - */ - hideBackdrop?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the horizontal alignment of the component. - */ - horizontalAlign?: - | (PopoverHorizontalAlign | keyof typeof PopoverHorizontalAlign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the component should close when clicking/tapping outside of the popover. If enabled, - * it blocks any interaction with the background. - */ - modal?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Indicates if the element is open - */ - open?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines on which side the component is placed at. - */ - placementType?: - | (PopoverPlacementType | keyof typeof PopoverPlacementType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines if the focus should be returned to the previously focused element, when the popup closes. - */ - preventFocusRestore?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the vertical alignment of the component. - */ - verticalAlign?: - | (PopoverVerticalAlign | keyof typeof PopoverVerticalAlign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the content of the Popup. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the footer HTML Element. - */ - footer?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the header HTML Element. - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the ID or DOM Reference of the element that the popover is shown at - */ - opener?: Control | string; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Defines the ID of the HTML Element, which will get the initial focus. - */ - initialFocus?: Control | string; - - /** - * Fired after the component is closed. **This event does not bubble.** - */ - afterClose?: (oEvent: Event) => void; - - /** - * Fired after the component is opened. **This event does not bubble.** - */ - afterOpen?: (oEvent: Event) => void; - - /** - * Fired before the component is closed. This event can be cancelled, which will prevent the popup from - * closing. **This event does not bubble.** - */ - beforeClose?: (oEvent: ResponsivePopover$BeforeCloseEvent) => void; - - /** - * Fired before the component is opened. This event can be cancelled, which will prevent the popup from - * opening. **This event does not bubble.** - */ - beforeOpen?: (oEvent: Event) => void; - } - - /** - * Parameters of the ResponsivePopover#afterClose event. - */ - export interface ResponsivePopover$AfterCloseEventParameters {} - - /** - * Event object of the ResponsivePopover#afterClose event. - */ - export type ResponsivePopover$AfterCloseEvent = Event< - ResponsivePopover$AfterCloseEventParameters, - ResponsivePopover - >; - - /** - * Parameters of the ResponsivePopover#afterOpen event. - */ - export interface ResponsivePopover$AfterOpenEventParameters {} - - /** - * Event object of the ResponsivePopover#afterOpen event. - */ - export type ResponsivePopover$AfterOpenEvent = Event< - ResponsivePopover$AfterOpenEventParameters, - ResponsivePopover - >; - - /** - * Parameters of the ResponsivePopover#beforeClose event. - */ - export interface ResponsivePopover$BeforeCloseEventParameters { - /** - * Indicates that `ESC` key has triggered the event. - */ - escPressed?: boolean; - } - - /** - * Event object of the ResponsivePopover#beforeClose event. - */ - export type ResponsivePopover$BeforeCloseEvent = Event< - ResponsivePopover$BeforeCloseEventParameters, - ResponsivePopover - >; - - /** - * Parameters of the ResponsivePopover#beforeOpen event. - */ - export interface ResponsivePopover$BeforeOpenEventParameters {} - - /** - * Event object of the ResponsivePopover#beforeOpen event. - */ - export type ResponsivePopover$BeforeOpenEvent = Event< - ResponsivePopover$BeforeOpenEventParameters, - ResponsivePopover - >; -} - -declare module "sap/ui/webc/main/SegmentedButton" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, CSSSize } from "sap/ui/core/library"; - - import { - ISegmentedButtonItem, - SegmentedButtonMode, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `sap.ui.webc.main.SegmentedButton` shows a group of items. When the user clicks or taps one of the - * items, it stays in a pressed state. It automatically resizes the items to fit proportionally within the - * component. When no width is set, the component uses the available width. - * - * **Note:** There can be just one selected `item` at a time. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class SegmentedButton - extends WebComponent - implements IFormContent - { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `SegmentedButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SegmentedButtonSettings - ); - /** - * Constructor for a new `SegmentedButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SegmentedButtonSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.SegmentedButton with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.SegmentedButton. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ISegmentedButtonItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.SegmentedButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SegmentedButton` itself. - * - * Fired when the selected item changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: SegmentedButton$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SegmentedButton` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.SegmentedButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SegmentedButton` itself. - * - * Fired when the selected item changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: SegmentedButton$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SegmentedButton` itself - */ - oListener?: object - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.main.SegmentedButton`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: SegmentedButton$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: SegmentedButton$SelectionChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * `SegmentedButton` must not be stretched in Form because ResizeHandler is used internally in order to - * manage the width of the SegmentedButton depending on the container size - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns True this method always returns `true` - */ - getFormDoNotAdjustWidth(): boolean; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of `sap.ui.webc.main.SegmentedButton`. - * - * **Note:** Multiple items are allowed. - * - * **Note:** Use the `sap.ui.webc.main.SegmentedButtonItem` for the intended design. - */ - getItems(): ISegmentedButtonItem[]; - /** - * Gets current value of property {@link #getMode mode}. - * - * Defines the component selection mode. - * - * - * - * **The available values are:** - * - * - * - `SingleSelect` - * - `MultiSelect` - * - * Default value is `SingleSelect`. - * - * - * @returns Value of property `mode` - */ - getMode(): SegmentedButtonMode; - /** - * Returns an array of the currently selected items. - */ - getSelectedItems(): void; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.ISegmentedButtonItem` in the aggregation {@link #getItems items}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ISegmentedButtonItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ISegmentedButtonItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ISegmentedButtonItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ISegmentedButtonItem - ): ISegmentedButtonItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getMode mode}. - * - * Defines the component selection mode. - * - * - * - * **The available values are:** - * - * - * - `SingleSelect` - * - `MultiSelect` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `SingleSelect`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMode( - /** - * New value for property `mode` - */ - sMode?: SegmentedButtonMode | keyof typeof SegmentedButtonMode - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the SegmentedButton constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SegmentedButtonSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the component selection mode. - * - * - * - * **The available values are:** - * - * - * - `SingleSelect` - * - `MultiSelect` - */ - mode?: - | (SegmentedButtonMode | keyof typeof SegmentedButtonMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the items of `sap.ui.webc.main.SegmentedButton`. - * - * **Note:** Multiple items are allowed. - * - * **Note:** Use the `sap.ui.webc.main.SegmentedButtonItem` for the intended design. - */ - items?: - | ISegmentedButtonItem[] - | ISegmentedButtonItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Fired when the selected item changes. - */ - selectionChange?: (oEvent: SegmentedButton$SelectionChangeEvent) => void; - } - - /** - * Parameters of the SegmentedButton#selectionChange event. - */ - export interface SegmentedButton$SelectionChangeEventParameters { - /** - * the pressed item. Note: deprecated since 1.14.0 and will be removed in the next major release, use the - * `selectedItems` parameter instead. - */ - selectedItem?: HTMLElement; - - /** - * an array of selected items. Note: available since 1.14.0. - */ - selectedItems?: HTMLElement[]; - } - - /** - * Event object of the SegmentedButton#selectionChange event. - */ - export type SegmentedButton$SelectionChangeEvent = Event< - SegmentedButton$SelectionChangeEventParameters, - SegmentedButton - >; -} - -declare module "sap/ui/webc/main/SegmentedButtonItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - ISegmentedButtonItem, - ButtonDesign, - ButtonType, - } from "sap/ui/webc/main/library"; - - import { ID } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * Users can use the `sap.ui.webc.main.SegmentedButtonItem` as part of a `sap.ui.webc.main.SegmentedButton`. - * - * - * Clicking or tapping on a `sap.ui.webc.main.SegmentedButtonItem` changes its state to `pressed`. The - * item returns to its initial state when the user clicks or taps on it again. By applying additional custom - * CSS-styling classes, apps can give a different style to any `sap.ui.webc.main.SegmentedButtonItem`. - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class SegmentedButtonItem - extends WebComponent - implements ISegmentedButtonItem - { - __implements__sap_ui_webc_main_ISegmentedButtonItem: boolean; - /** - * Constructor for a new `SegmentedButtonItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SegmentedButtonItemSettings - ); - /** - * Constructor for a new `SegmentedButtonItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SegmentedButtonItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.SegmentedButtonItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.SegmentedButtonItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.SegmentedButtonItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SegmentedButtonItem` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SegmentedButtonItem` - * itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.SegmentedButtonItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SegmentedButtonItem` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SegmentedButtonItem` - * itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.SegmentedButtonItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getDesign design}. - * - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): ButtonDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIconEnd iconEnd}. - * - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - * - * Default value is `false`. - * - * - * @returns Value of property `iconEnd` - */ - getIconEnd(): boolean; - /** - * Gets current value of property {@link #getPressed pressed}. - * - * Determines whether the component is displayed as pressed. - * - * Default value is `false`. - * - * - * @returns Value of property `pressed` - */ - getPressed(): boolean; - /** - * Gets current value of property {@link #getSubmits submits}. - * - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - * - * Default value is `false`. - * - * - * @returns Value of property `submits` - */ - getSubmits(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getType type}. - * - * Defines whether the button has special form-related functionality. - * - * Default value is `Button`. - * - * - * @returns Value of property `type` - */ - getType(): ButtonType; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: ButtonDesign | keyof typeof ButtonDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getIconEnd iconEnd}. - * - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIconEnd( - /** - * New value for property `iconEnd` - */ - bIconEnd?: boolean - ): this; - /** - * Sets a new value for property {@link #getPressed pressed}. - * - * Determines whether the component is displayed as pressed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPressed( - /** - * New value for property `pressed` - */ - bPressed?: boolean - ): this; - /** - * Sets a new value for property {@link #getSubmits submits}. - * - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSubmits( - /** - * New value for property `submits` - */ - bSubmits?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines whether the button has special form-related functionality. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Button`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ButtonType | keyof typeof ButtonType - ): this; - } - /** - * Describes the settings that can be provided to the SegmentedButtonItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $SegmentedButtonItemSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - */ - design?: - | (ButtonDesign | keyof typeof ButtonDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - */ - iconEnd?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines whether the component is displayed as pressed. - */ - pressed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * **Note:** The property is inherited and not supported. If set, it won't take any effect. - */ - submits?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines whether the button has special form-related functionality. - */ - type?: - | (ButtonType | keyof typeof ButtonType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the SegmentedButtonItem#click event. - */ - export interface SegmentedButtonItem$ClickEventParameters {} - - /** - * Event object of the SegmentedButtonItem#click event. - */ - export type SegmentedButtonItem$ClickEvent = Event< - SegmentedButtonItem$ClickEventParameters, - SegmentedButtonItem - >; -} - -declare module "sap/ui/webc/main/Select" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { ISelectOption } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Select` component is used to create a drop-down list. - * - * Usage: - * - * There are two main usages of the `ui5-select>`. - * - * 1. With Option (`sap.ui.webc.main.Option`) web component: - * The available options of the Select are defined by using the Option component. The Option comes with - * predefined design and layout, including `icon`, `text` and `additional-text`. - * - * - * - * 2. With SelectMenu (`sap.ui.webc.main.SelectMenu`) and SelectMenuOption (`sap.ui.webc.main.SelectMenuOption`) - * web components: - * The SelectMenu can be used as alternative to define the Select's dropdown and can be used via the `menu` - * property of the Select to reference SelectMenu by its ID. The component gives the possibility to customize - * the Select's dropdown by slotting entirely custom options (via the SelectMenuOption component) and adding - * custom styles. - * - * **Note:** SelectMenu is a popover and placing it top-level in the HTML page is recommended, because some - * page styles (for example transitions) can misplace the SelectMenu. - * - * Keyboard Handling: The `sap.ui.webc.main.Select` provides advanced keyboard handling. - * - * - * - * - [F4, ALT+UP, ALT+DOWN, SPACE, ENTER] - Opens/closes the drop-down. - * - [UP, DOWN] - If the drop-down is closed - changes selection to the next or the previous option. If - * the drop-down is opened - moves focus to the next or the previous option. - * - [SPACE, ENTER] - If the drop-down is opened - selects the focused option. - * - [ESC] - Closes the drop-down without changing the selection. - * - [HOME] - Navigates to first option - * - [END] - Navigates to the last option - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Select extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `Select`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SelectSettings - ); - /** - * Constructor for a new `Select`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SelectSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Select with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Select. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some label to the aggregation {@link #getLabel label}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addLabel( - /** - * The label to add; if empty, nothing is inserted - */ - oLabel: Control - ): this; - /** - * Adds some option to the aggregation {@link #getOptions options}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addOption( - /** - * The option to add; if empty, nothing is inserted - */ - oOption: ISelectOption - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired when the selected option changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Select$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired when the selected option changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Select$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired after the component's dropdown menu closes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired after the component's dropdown menu closes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:liveChange liveChange} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired when the user navigates through the options, but the selection is not finalized, or when pressing - * the ESC key to revert the current selection. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLiveChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Select$LiveChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:liveChange liveChange} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired when the user navigates through the options, but the selection is not finalized, or when pressing - * the ESC key to revert the current selection. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLiveChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Select$LiveChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:open open} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired after the component's dropdown menu opens. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:open open} event of this `sap.ui.webc.main.Select`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Select` itself. - * - * Fired after the component's dropdown menu opens. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Select` itself - */ - oListener?: object - ): this; - /** - * Destroys all the label in the aggregation {@link #getLabel label}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyLabel(): this; - /** - * Destroys all the options in the aggregation {@link #getOptions options}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyOptions(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.Select`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Select$ChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:close close} event of this `sap.ui.webc.main.Select`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:liveChange liveChange} event of this `sap.ui.webc.main.Select`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachLiveChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Select$LiveChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:open open} event of this `sap.ui.webc.main.Select`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: Select$ChangeEventParameters - ): boolean; - /** - * Fires event {@link #event:close close} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClose( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:liveChange liveChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireLiveChange( - /** - * Parameters to pass along with the event - */ - mParameters?: Select$LiveChangeEventParameters - ): this; - /** - * Fires event {@link #event:open open} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets content of aggregation {@link #getLabel label}. - * - * Defines the HTML element that will be displayed in the component input part, representing the selected - * option. - * - * - * - * **Note:** If not specified and `sap.ui.webc.main.SelectMenuOption` is used, either the option's `display-text` - * or its textContent will be displayed. - * - * - * - * **Note:** If not specified and `sap.ui.webc.main.Option` is used, the option's textContent will be displayed. - */ - getLabel(): Control[]; - /** - * ID of the element which is the current target of the association {@link #getMenu menu}, or `null`. - */ - getMenu(): ID | null; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. The value of the component - * will be the value of the currently selected `sap.ui.webc.main.Option`. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the `sap.ui.webc.main.Select` - * so that it can be submitted as part of an HTML form. Do not use this property unless you need to submit - * a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets content of aggregation {@link #getOptions options}. - * - * Defines the component options. - * - * - * - * **Note:** Only one selected option is allowed. If more than one option is defined as selected, the last - * one would be considered as the selected one. - * - * - * - * **Note:** Use the `sap.ui.webc.main.Option` component to define the desired options. - */ - getOptions(): ISelectOption[]; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Returns the currently selected `ui5-option` element. - */ - getSelectedOption(): void; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getLabel label}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfLabel( - /** - * The label whose index is looked for - */ - oLabel: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.main.ISelectOption` in the aggregation {@link #getOptions options}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfOption( - /** - * The option whose index is looked for - */ - oOption: ISelectOption - ): int; - /** - * Inserts a label into the aggregation {@link #getLabel label}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertLabel( - /** - * The label to insert; if empty, nothing is inserted - */ - oLabel: Control, - /** - * The `0`-based index the label should be inserted at; for a negative value of `iIndex`, the label is inserted - * at position 0; for a value greater than the current size of the aggregation, the label is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Inserts a option into the aggregation {@link #getOptions options}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertOption( - /** - * The option to insert; if empty, nothing is inserted - */ - oOption: ISelectOption, - /** - * The `0`-based index the option should be inserted at; for a negative value of `iIndex`, the option is - * inserted at position 0; for a value greater than the current size of the aggregation, the option is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getLabel label}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllLabel(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getOptions options}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllOptions(): ISelectOption[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a label from the aggregation {@link #getLabel label}. - * - * - * @returns The removed label or `null` - */ - removeLabel( - /** - * The label to remove or its index or id - */ - vLabel: int | string | Control - ): Control | null; - /** - * Removes a option from the aggregation {@link #getOptions options}. - * - * - * @returns The removed option or `null` - */ - removeOption( - /** - * The option to remove or its index or id - */ - vOption: int | string | ISelectOption - ): ISelectOption | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets the associated {@link #getMenu menu}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMenu( - /** - * ID of an element which becomes the new target of this menu association; alternatively, an element instance - * may be given - */ - oMenu: ID | Control - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. The value of the component - * will be the value of the currently selected `sap.ui.webc.main.Option`. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the `sap.ui.webc.main.Select` - * so that it can be submitted as part of an HTML form. Do not use this property unless you need to submit - * a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Select constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SelectSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. The value of the component - * will be the value of the currently selected `sap.ui.webc.main.Option`. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the `sap.ui.webc.main.Select` - * so that it can be submitted as part of an HTML form. Do not use this property unless you need to submit - * a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the value state of the component. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the HTML element that will be displayed in the component input part, representing the selected - * option. - * - * - * - * **Note:** If not specified and `sap.ui.webc.main.SelectMenuOption` is used, either the option's `display-text` - * or its textContent will be displayed. - * - * - * - * **Note:** If not specified and `sap.ui.webc.main.Option` is used, the option's textContent will be displayed. - */ - label?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the component options. - * - * - * - * **Note:** Only one selected option is allowed. If more than one option is defined as selected, the last - * one would be considered as the selected one. - * - * - * - * **Note:** Use the `sap.ui.webc.main.Option` component to define the desired options. - */ - options?: - | ISelectOption[] - | ISelectOption - | AggregationBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Defines a reference (ID or DOM element) of component's menu of options as alternative to define the select's - * dropdown. - * - * **Note:** Usage of `sap.ui.webc.main.SelectMenu` is recommended. - */ - menu?: Control | string; - - /** - * Fired when the selected option changes. - */ - change?: (oEvent: Select$ChangeEvent) => void; - - /** - * Fired after the component's dropdown menu closes. - */ - close?: (oEvent: Event) => void; - - /** - * Fired when the user navigates through the options, but the selection is not finalized, or when pressing - * the ESC key to revert the current selection. - */ - liveChange?: (oEvent: Select$LiveChangeEvent) => void; - - /** - * Fired after the component's dropdown menu opens. - */ - open?: (oEvent: Event) => void; - } - - /** - * Parameters of the Select#change event. - */ - export interface Select$ChangeEventParameters { - /** - * the selected option. - */ - selectedOption?: HTMLElement; - } - - /** - * Event object of the Select#change event. - */ - export type Select$ChangeEvent = Event; - - /** - * Parameters of the Select#close event. - */ - export interface Select$CloseEventParameters {} - - /** - * Event object of the Select#close event. - */ - export type Select$CloseEvent = Event; - - /** - * Parameters of the Select#liveChange event. - */ - export interface Select$LiveChangeEventParameters { - /** - * the selected option. - */ - selectedOption?: HTMLElement; - } - - /** - * Event object of the Select#liveChange event. - */ - export type Select$LiveChangeEvent = Event< - Select$LiveChangeEventParameters, - Select - >; - - /** - * Parameters of the Select#open event. - */ - export interface Select$OpenEventParameters {} - - /** - * Event object of the Select#open event. - */ - export type Select$OpenEvent = Event; -} - -declare module "sap/ui/webc/main/SelectMenu" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ISelectMenuOption } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { AggregationBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.SelectMenu` is meant to be used together with the `sap.ui.webc.main.Select` component - * as alternative to define the select's dropdown. It acts as a popover on desktop and tablet, and as a - * Dialog on phone. - * - * The component gives the possibility to the user to customize the `sap.ui.webc.main.Select`'s dropdown - * by slotting custom options and adding custom styles. - * - * Usage: - * - * To use `sap.ui.webc.main.Select` with a `sap.ui.webc.main.SelectMenu`, you need to set the `sap.ui.webc.main.Select` - * `menu` property to reference `sap.ui.webc.main.SelectMenu` either by ID or DOM reference. - * - * - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class SelectMenu extends WebComponent { - /** - * Constructor for a new `SelectMenu`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SelectMenuSettings - ); - /** - * Constructor for a new `SelectMenu`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SelectMenuSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.SelectMenu with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.SelectMenu. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: ISelectMenuOption - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the options of the component. - */ - getContent(): ISelectMenuOption[]; - /** - * Checks for the provided `sap.ui.webc.main.ISelectMenuOption` in the aggregation {@link #getContent content}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: ISelectMenuOption - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: ISelectMenuOption, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): ISelectMenuOption[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | ISelectMenuOption - ): ISelectMenuOption | null; - } - /** - * Describes the settings that can be provided to the SelectMenu constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $SelectMenuSettings extends $WebComponentSettings { - /** - * Defines the options of the component. - */ - content?: - | ISelectMenuOption[] - | ISelectMenuOption - | AggregationBindingInfo - | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/SelectMenuOption" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ISelectMenuOption } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The code>ui5-select-menu-option component represents an option in the `sap.ui.webc.main.SelectMenu`. - * - * Usage: - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class SelectMenuOption - extends WebComponent - implements ISelectMenuOption - { - __implements__sap_ui_webc_main_ISelectMenuOption: boolean; - /** - * Constructor for a new `SelectMenuOption`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SelectMenuOptionSettings - ); - /** - * Constructor for a new `SelectMenuOption`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SelectMenuOptionSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.SelectMenuOption with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.SelectMenuOption. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the component. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getDisplayText displayText}. - * - * Defines the text, displayed inside the `sap.ui.webc.main.Select` input filed when the option gets selected. - * - * - * @returns Value of property `displayText` - */ - getDisplayText(): string; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the value of the `sap.ui.webc.main.Select` inside an HTML Form element when this component is - * selected. For more information on HTML Form support, see the `name` property of `sap.ui.webc.main.Select`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getDisplayText displayText}. - * - * Defines the text, displayed inside the `sap.ui.webc.main.Select` input filed when the option gets selected. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDisplayText( - /** - * New value for property `displayText` - */ - sDisplayText: string - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the value of the `sap.ui.webc.main.Select` inside an HTML Form element when this component is - * selected. For more information on HTML Form support, see the `name` property of `sap.ui.webc.main.Select`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue: string - ): this; - } - /** - * Describes the settings that can be provided to the SelectMenuOption constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $SelectMenuOptionSettings extends $WebComponentSettings { - /** - * Defines the text, displayed inside the `sap.ui.webc.main.Select` input filed when the option gets selected. - */ - displayText?: string | PropertyBindingInfo; - - /** - * Defines the value of the `sap.ui.webc.main.Select` inside an HTML Form element when this component is - * selected. For more information on HTML Form support, see the `name` property of `sap.ui.webc.main.Select`. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the content of the component. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/Slider" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, CSSSize } from "sap/ui/core/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The Slider component represents a numerical range and a handle (grip). The purpose of the component - * is to enable visual selection of a value in a continuous numerical range by moving an adjustable handle. - * - * Structure: The most important properties of the Slider are: - * - min - The minimum value of the slider range. - * - max - The maximum value of the slider range. - * - value - The current value of the slider range. - * - step - Determines the increments in which the slider will move. - * - showTooltip - Determines if a tooltip should be displayed above the handle. - * - showTickmarks - Displays a visual divider between the step values. - * - labelInterval - Labels some or all of the tickmarks with their values. - * - * Usage: The most common use case is to select values on a continuous numerical scale (e.g. temperature, - * volume, etc. ). - * - * Responsive Behavior: The `sap.ui.webc.main.Slider` component adjusts to the size of its parent container - * by recalculating and resizing the width of the control. You can move the slider handle in several different - * ways: - * - Drag and drop the handle to the desired value. - * - Click/tap on the range bar to move the handle to that location. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Slider` exposes the following CSS Shadow Parts: - * - progress-container - Used to style the progress container(the horizontal bar which visually represents - * the range between the minimum and maximum value) of the `sap.ui.webc.main.Slider`. - * - progress-bar - Used to style the progress bar, which shows the progress of the `sap.ui.webc.main.Slider`. - * - * - handle - Used to style the handle of the `sap.ui.webc.main.Slider`. - * - * Keyboard Handling: - * - * - * - `Left or Down Arrow` - Moves the handle one step to the left, effectively decreasing the component's - * value by `step` amount; - * - `Right or Up Arrow` - Moves the handle one step to the right, effectively increasing the component's - * value by `step` amount; - * - `Left or Down Arrow + Ctrl/Cmd` - Moves the handle to the left with step equal to 1/10th of the entire - * range, effectively decreasing the component's value by 1/10th of the range; - * - `Right or Up Arrow + Ctrl/Cmd` - Moves the handle to the right with step equal to 1/10th of the entire - * range, effectively increasing the component's value by 1/10th of the range; - * - `Plus` - Same as `Right or Up Arrow`; - * - `Minus` - Same as `Left or Down Arrow`; - * - `Home` - Moves the handle to the beginning of the range; - * - `End` - Moves the handle to the end of the range; - * - `Page Up` - Same as `Right or Up + Ctrl/Cmd`; - * - `Page Down` - Same as `Left or Down + Ctrl/Cmd`; - * - `Escape` - Resets the value property after interaction, to the position prior the component's focusing; - * - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Slider extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `Slider`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SliderSettings - ); - /** - * Constructor for a new `Slider`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SliderSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Slider with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Slider. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Slider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Slider` itself. - * - * Fired when the value changes and the user has finished interacting with the slider. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Slider` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Slider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Slider` itself. - * - * Fired when the value changes and the user has finished interacting with the slider. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Slider` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.Slider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Slider` itself. - * - * Fired when the value changes due to user interaction that is not yet finished - during mouse/touch dragging. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Slider` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.Slider`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Slider` itself. - * - * Fired when the value changes due to user interaction that is not yet finished - during mouse/touch dragging. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Slider` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.Slider`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.Slider`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getLabelInterval labelInterval}. - * - * Displays a label with a value on every N-th step. - * - * **Note:** The step and tickmarks properties must be enabled. Example - if the step value is set to 2 - * and the label interval is also specified to 2 - then every second tickmark will be labelled, which means - * every 4th value number. - * - * Default value is `0`. - * - * - * @returns Value of property `labelInterval` - */ - getLabelInterval(): int; - /** - * Gets current value of property {@link #getMax max}. - * - * Defines the maximum value of the slider. - * - * Default value is `100`. - * - * - * @returns Value of property `max` - */ - getMax(): float; - /** - * Gets current value of property {@link #getMin min}. - * - * Defines the minimum value of the slider. - * - * Default value is `0`. - * - * - * @returns Value of property `min` - */ - getMin(): float; - /** - * Gets current value of property {@link #getShowTickmarks showTickmarks}. - * - * Enables tickmarks visualization for each step. - * - * **Note:** The step must be a positive number. - * - * Default value is `false`. - * - * - * @returns Value of property `showTickmarks` - */ - getShowTickmarks(): boolean; - /** - * Gets current value of property {@link #getShowTooltip showTooltip}. - * - * Enables handle tooltip displaying the current value. - * - * Default value is `false`. - * - * - * @returns Value of property `showTooltip` - */ - getShowTooltip(): boolean; - /** - * Gets current value of property {@link #getStep step}. - * - * Defines the size of the slider's selection intervals (e.g. min = 0, max = 10, step = 5 would result in - * possible selection of the values 0, 5, 10). - * - * **Note:** If set to 0 the slider handle movement is disabled. When negative number or value other than - * a number, the component fallbacks to its default value. - * - * Default value is `1`. - * - * - * @returns Value of property `step` - */ - getStep(): int; - /** - * Gets current value of property {@link #getValue value}. - * - * Current value of the slider - * - * Default value is `0`. - * - * - * @returns Value of property `value` - */ - getValue(): float; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getLabelInterval labelInterval}. - * - * Displays a label with a value on every N-th step. - * - * **Note:** The step and tickmarks properties must be enabled. Example - if the step value is set to 2 - * and the label interval is also specified to 2 - then every second tickmark will be labelled, which means - * every 4th value number. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLabelInterval( - /** - * New value for property `labelInterval` - */ - iLabelInterval?: int - ): this; - /** - * Sets a new value for property {@link #getMax max}. - * - * Defines the maximum value of the slider. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `100`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMax( - /** - * New value for property `max` - */ - fMax?: float - ): this; - /** - * Sets a new value for property {@link #getMin min}. - * - * Defines the minimum value of the slider. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMin( - /** - * New value for property `min` - */ - fMin?: float - ): this; - /** - * Sets a new value for property {@link #getShowTickmarks showTickmarks}. - * - * Enables tickmarks visualization for each step. - * - * **Note:** The step must be a positive number. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowTickmarks( - /** - * New value for property `showTickmarks` - */ - bShowTickmarks?: boolean - ): this; - /** - * Sets a new value for property {@link #getShowTooltip showTooltip}. - * - * Enables handle tooltip displaying the current value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowTooltip( - /** - * New value for property `showTooltip` - */ - bShowTooltip?: boolean - ): this; - /** - * Sets a new value for property {@link #getStep step}. - * - * Defines the size of the slider's selection intervals (e.g. min = 0, max = 10, step = 5 would result in - * possible selection of the values 0, 5, 10). - * - * **Note:** If set to 0 the slider handle movement is disabled. When negative number or value other than - * a number, the component fallbacks to its default value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStep( - /** - * New value for property `step` - */ - iStep?: int - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Current value of the slider - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - fValue?: float - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Slider constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SliderSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Displays a label with a value on every N-th step. - * - * **Note:** The step and tickmarks properties must be enabled. Example - if the step value is set to 2 - * and the label interval is also specified to 2 - then every second tickmark will be labelled, which means - * every 4th value number. - */ - labelInterval?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the maximum value of the slider. - */ - max?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the minimum value of the slider. - */ - min?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Enables tickmarks visualization for each step. - * - * **Note:** The step must be a positive number. - */ - showTickmarks?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Enables handle tooltip displaying the current value. - */ - showTooltip?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the size of the slider's selection intervals (e.g. min = 0, max = 10, step = 5 would result in - * possible selection of the values 0, 5, 10). - * - * **Note:** If set to 0 the slider handle movement is disabled. When negative number or value other than - * a number, the component fallbacks to its default value. - */ - step?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Current value of the slider - */ - value?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Fired when the value changes and the user has finished interacting with the slider. - */ - change?: (oEvent: Event) => void; - - /** - * Fired when the value changes due to user interaction that is not yet finished - during mouse/touch dragging. - */ - input?: (oEvent: Event) => void; - } - - /** - * Parameters of the Slider#change event. - */ - export interface Slider$ChangeEventParameters {} - - /** - * Event object of the Slider#change event. - */ - export type Slider$ChangeEvent = Event; - - /** - * Parameters of the Slider#input event. - */ - export interface Slider$InputEventParameters {} - - /** - * Event object of the Slider#input event. - */ - export type Slider$InputEvent = Event; -} - -declare module "sap/ui/webc/main/SplitButton" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import Event from "sap/ui/base/Event"; - - import { ButtonDesign } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * `sap.ui.webc.main.SplitButton` enables users to trigger actions. It is constructed of two separate actions - * - default action and arrow action that can be activated by clicking or tapping, or by pressing certain - * keyboard keys - `Space` or `Enter` for default action, and `Arrow Down` or `Arrow Up` for arrow action. - * - * Usage: - * - * `sap.ui.webc.main.SplitButton` consists two separate buttons: - * - for the first one (default action) you can define some `text` or an `icon`, or both. Also, it is - * possible to define different icon for active state of this button - `activeIcon`. - * - the second one (arrow action) contains only `slim-arrow-down` icon. You can choose a `design` - * from a set of predefined types (the same as for ui5-button) that offer different styling to correspond - * to the triggered action. Both text and arrow actions have the same design. - * - * You can set the `sap.ui.webc.main.SplitButton` as enabled or disabled. Both parts of an enabled `sap.ui.webc.main.SplitButton` - * can be pressed by clicking or tapping it, or by certain keys, which changes the style to provide visual - * feedback to the user that it is pressed or hovered over with the mouse cursor. A disabled `sap.ui.webc.main.SplitButton` - * appears inactive and any of the two buttons cannot be pressed. - * - * Keyboard Handling: - * - `Space` or `Enter` - triggers the default action - * - `Shift` or `Escape` - if `Space` is pressed, releases the default action button without triggering - * the click event. - * - `Arrow Down`, `Arrow Up`, `Alt`+`Arrow Down`, `Alt`+`Arrow Up`, or `F4` - triggers the arrow action - * There are separate events that are fired on activating of `sap.ui.webc.main.SplitButton` parts: - * - * - `click` for the first button (default action) - * - `arrow-click` for the second button (arrow action) - * - * @since 1.99.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export default class SplitButton extends WebComponent { - /** - * Constructor for a new `SplitButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SplitButtonSettings - ); - /** - * Constructor for a new `SplitButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SplitButtonSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.SplitButton with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.SplitButton. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:arrowClick arrowClick} event of this `sap.ui.webc.main.SplitButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SplitButton` itself. - * - * Fired when the user clicks on the arrow action. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachArrowClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SplitButton` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:arrowClick arrowClick} event of this `sap.ui.webc.main.SplitButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SplitButton` itself. - * - * Fired when the user clicks on the arrow action. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachArrowClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SplitButton` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.SplitButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SplitButton` itself. - * - * Fired when the user clicks on the default action. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SplitButton` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.SplitButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.SplitButton` itself. - * - * Fired when the user clicks on the default action. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.SplitButton` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:arrowClick arrowClick} event of this `sap.ui.webc.main.SplitButton`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachArrowClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.SplitButton`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:arrowClick arrowClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireArrowClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getActiveIcon activeIcon}. - * - * Defines the icon to be displayed in active state as graphical element within the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `activeIcon` - */ - getActiveIcon(): string; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component design. - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): ButtonDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon to be displayed as graphical element within the component. The SAP-icons font provides - * numerous options. - * - * Example: - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getActiveIcon activeIcon}. - * - * Defines the icon to be displayed in active state as graphical element within the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setActiveIcon( - /** - * New value for property `activeIcon` - */ - sActiveIcon?: string - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: ButtonDesign | keyof typeof ButtonDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon to be displayed as graphical element within the component. The SAP-icons font provides - * numerous options. - * - * Example: - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the SplitButton constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.99.0. This control is experimental and its API might change significantly. - */ - export interface $SplitButtonSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the icon to be displayed in active state as graphical element within the component. - */ - activeIcon?: string | PropertyBindingInfo; - - /** - * Defines the component design. - */ - design?: - | (ButtonDesign | keyof typeof ButtonDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon to be displayed as graphical element within the component. The SAP-icons font provides - * numerous options. - * - * Example: - * - * See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Fired when the user clicks on the arrow action. - */ - arrowClick?: (oEvent: Event) => void; - - /** - * Fired when the user clicks on the default action. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the SplitButton#arrowClick event. - */ - export interface SplitButton$ArrowClickEventParameters {} - - /** - * Event object of the SplitButton#arrowClick event. - */ - export type SplitButton$ArrowClickEvent = Event< - SplitButton$ArrowClickEventParameters, - SplitButton - >; - - /** - * Parameters of the SplitButton#click event. - */ - export interface SplitButton$ClickEventParameters {} - - /** - * Event object of the SplitButton#click event. - */ - export type SplitButton$ClickEvent = Event< - SplitButton$ClickEventParameters, - SplitButton - >; -} - -declare module "sap/ui/webc/main/StandardListItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IListItem, IButton, ListItemType } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { ValueState } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.StandardListItem` represents the simplest type of item for a `sap.ui.webc.main.List`. - * - * This is a list item, providing the most common use cases such as `text`, `image` and `icon`. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.StandardListItem` exposes the following CSS Shadow Parts: - * - title - Used to style the title of the list item - * - description - Used to style the description of the list item - * - additional-text - Used to style the additionalText of the list item - * - icon - Used to style the icon of the list item - * - native-li - Used to style the main li tag of the list item - * - content - Used to style the content area of the list item - * - detail-button - Used to style the button rendered when the list item is of type detail - * - delete-button - Used to style the button rendered when the list item is in delete mode - * - radio - Used to style the radio button rendered when the list item is in single selection mode - * - checkbox - Used to style the checkbox rendered when the list item is in multiple selection mode - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class StandardListItem - extends WebComponent - implements IListItem - { - __implements__sap_ui_webc_main_IListItem: boolean; - /** - * Constructor for a new `StandardListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $StandardListItemSettings - ); - /** - * Constructor for a new `StandardListItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $StandardListItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.StandardListItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.StandardListItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some imageContent to the aggregation {@link #getImageContent imageContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addImageContent( - /** - * The imageContent to add; if empty, nothing is inserted - */ - oImageContent: Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.StandardListItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.StandardListItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.StandardListItem` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.StandardListItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.StandardListItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.StandardListItem` itself - */ - oListener?: object - ): this; - /** - * Destroys the deleteButton in the aggregation {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyDeleteButton(): this; - /** - * Destroys all the imageContent in the aggregation {@link #getImageContent imageContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyImageContent(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.StandardListItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachDetailClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:detailClick detailClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireDetailClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the list item. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - * - * Default value is `None`. - * - * - * @returns Value of property `additionalTextState` - */ - getAdditionalTextState(): ValueState; - /** - * Gets content of aggregation {@link #getDeleteButton deleteButton}. - * - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - getDeleteButton(): IButton; - /** - * Gets current value of property {@link #getDescription description}. - * - * Defines the description displayed right under the item text, if such is present. - * - * - * @returns Value of property `description` - */ - getDescription(): string; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIconEnd iconEnd}. - * - * Defines whether the `icon` should be displayed in the beginning of the list item or in the end. - * - * **Note:** If `image` is set, the `icon` would be displayed after the `image`. - * - * Default value is `false`. - * - * - * @returns Value of property `iconEnd` - */ - getIconEnd(): boolean; - /** - * Gets current value of property {@link #getImage image}. - * - * Defines the `image` source URI. - * - * **Note:** The `image` would be displayed in the beginning of the list item. - * - * - * @returns Value of property `image` - */ - getImage(): string; - /** - * Gets content of aggregation {@link #getImageContent imageContent}. - * - * **Note:** While the slot allows option for setting custom avatar, to match the design guidelines, please - * use the `sap.ui.webc.main.Avatar` with it`s default size - S. **Note:** If bigger `sap.ui.webc.main.Avatar` - * needs to be used, then the size of the `sap.ui.webc.main.StandardListItem` should be customized in order - * to fit. - */ - getImageContent(): Control[]; - /** - * Gets current value of property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * - * @returns Value of property `navigated` - */ - getNavigated(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * Default value is `Active`. - * - * - * @returns Value of property `type` - */ - getType(): ListItemType; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getImageContent imageContent}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfImageContent( - /** - * The imageContent whose index is looked for - */ - oImageContent: Control - ): int; - /** - * Inserts a imageContent into the aggregation {@link #getImageContent imageContent}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertImageContent( - /** - * The imageContent to insert; if empty, nothing is inserted - */ - oImageContent: Control, - /** - * The `0`-based index the imageContent should be inserted at; for a negative value of `iIndex`, the imageContent - * is inserted at position 0; for a value greater than the current size of the aggregation, the imageContent - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getImageContent imageContent}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllImageContent(): Control[]; - /** - * Removes a imageContent from the aggregation {@link #getImageContent imageContent}. - * - * - * @returns The removed imageContent or `null` - */ - removeImageContent( - /** - * The imageContent to remove or its index or id - */ - vImageContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText: string - ): this; - /** - * Sets a new value for property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalTextState( - /** - * New value for property `additionalTextState` - */ - sAdditionalTextState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets the aggregated {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDeleteButton( - /** - * The deleteButton to set - */ - oDeleteButton: IButton - ): this; - /** - * Sets a new value for property {@link #getDescription description}. - * - * Defines the description displayed right under the item text, if such is present. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDescription( - /** - * New value for property `description` - */ - sDescription: string - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon: string - ): this; - /** - * Sets a new value for property {@link #getIconEnd iconEnd}. - * - * Defines whether the `icon` should be displayed in the beginning of the list item or in the end. - * - * **Note:** If `image` is set, the `icon` would be displayed after the `image`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIconEnd( - /** - * New value for property `iconEnd` - */ - bIconEnd?: boolean - ): this; - /** - * Sets a new value for property {@link #getImage image}. - * - * Defines the `image` source URI. - * - * **Note:** The `image` would be displayed in the beginning of the list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setImage( - /** - * New value for property `image` - */ - sImage: string - ): this; - /** - * Sets a new value for property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNavigated( - /** - * New value for property `navigated` - */ - bNavigated: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Active`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ListItemType | keyof typeof ListItemType - ): this; - } - /** - * Describes the settings that can be provided to the StandardListItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $StandardListItemSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text alternative of the component. Note: If not provided a default text alternative will - * be set, if present. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the `additionalText`, displayed in the end of the list item. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - */ - additionalTextState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the description displayed right under the item text, if such is present. - */ - description?: string | PropertyBindingInfo; - - /** - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the `icon` should be displayed in the beginning of the list item or in the end. - * - * **Note:** If `image` is set, the `icon` would be displayed after the `image`. - */ - iconEnd?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `image` source URI. - * - * **Note:** The `image` would be displayed in the beginning of the list item. - */ - image?: string | PropertyBindingInfo; - - /** - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - */ - navigated?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - */ - type?: - | (ListItemType | keyof typeof ListItemType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - deleteButton?: IButton; - - /** - * **Note:** While the slot allows option for setting custom avatar, to match the design guidelines, please - * use the `sap.ui.webc.main.Avatar` with it`s default size - S. **Note:** If bigger `sap.ui.webc.main.Avatar` - * needs to be used, then the size of the `sap.ui.webc.main.StandardListItem` should be customized in order - * to fit. - */ - imageContent?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the user clicks on the detail button when type is `Detail`. - */ - detailClick?: (oEvent: Event) => void; - } - - /** - * Parameters of the StandardListItem#detailClick event. - */ - export interface StandardListItem$DetailClickEventParameters {} - - /** - * Event object of the StandardListItem#detailClick event. - */ - export type StandardListItem$DetailClickEvent = Event< - StandardListItem$DetailClickEventParameters, - StandardListItem - >; -} - -declare module "sap/ui/webc/main/StepInput" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.StepInput` consists of an input field and buttons with icons to increase/decrease - * the value with the predefined step. - * - * The user can change the value of the component by pressing the increase/decrease buttons, by typing - * a number directly, by using the keyboard up/down and page up/down, or by using the mouse scroll wheel. - * Decimal values are supported. - * - * Usage: - * - * The default step is 1 but the app developer can set a different one. - * - * App developers can set a maximum and minimum value for the `StepInput`. The increase/decrease button - * and the up/down keyboard navigation become disabled when the value reaches the max/min or a new value - * is entered from the input which is greater/less than the max/min. - * - * When to use:: - * - To adjust amounts, quantities, or other values quickly. - * - To adjust values for a specific step. - * - * When not to use:: - * - To enter a static number (for example, postal code, phone number, or ID). In this case, use the regular - * `sap.ui.webc.main.Input` instead. - * - To display a value that rarely needs to be adjusted and does not pertain to a particular step. In - * this case, use the regular `sap.ui.webc.main.Input` instead. - * - To enter dates and times. In this case, use date/time related components instead. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class StepInput extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `StepInput`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $StepInputSettings - ); - /** - * Constructor for a new `StepInput`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $StepInputSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.StepInput with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.StepInput. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.StepInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.StepInput` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.StepInput` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.StepInput`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.StepInput` itself. - * - * Fired when the input operation has finished by pressing Enter or on focusout. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.StepInput` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.StepInput`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getMax max}. - * - * Defines a maximum value of the component. - * - * - * @returns Value of property `max` - */ - getMax(): float; - /** - * Gets current value of property {@link #getMin min}. - * - * Defines a minimum value of the component. - * - * - * @returns Value of property `min` - */ - getMin(): float; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * Default value is `undefined`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getStep step}. - * - * Defines a step of increasing/decreasing the value of the component. - * - * Default value is `1`. - * - * - * @returns Value of property `step` - */ - getStep(): float; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines a value of the component. - * - * Default value is `0`. - * - * - * @returns Value of property `value` - */ - getValue(): float; - /** - * Gets current value of property {@link #getValuePrecision valuePrecision}. - * - * Determines the number of digits after the decimal point of the component. - * - * Default value is `0`. - * - * - * @returns Value of property `valuePrecision` - */ - getValuePrecision(): int; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getMax max}. - * - * Defines a maximum value of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMax( - /** - * New value for property `max` - */ - fMax: float - ): this; - /** - * Sets a new value for property {@link #getMin min}. - * - * Defines a minimum value of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMin( - /** - * New value for property `min` - */ - fMin: float - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Determines whether the component is displayed as read-only. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getStep step}. - * - * Defines a step of increasing/decreasing the value of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStep( - /** - * New value for property `step` - */ - fStep?: float - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines a value of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - fValue?: float - ): this; - /** - * Sets a new value for property {@link #getValuePrecision valuePrecision}. - * - * Determines the number of digits after the decimal point of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValuePrecision( - /** - * New value for property `valuePrecision` - */ - iValuePrecision?: int - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the StepInput constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $StepInputSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a maximum value of the component. - */ - max?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a minimum value of the component. - */ - min?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Determines whether the component is displayed as read-only. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a step of increasing/decreasing the value of the component. - */ - step?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a value of the component. - */ - value?: float | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the number of digits after the decimal point of the component. - */ - valuePrecision?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the input operation has finished by pressing Enter or on focusout. - */ - change?: (oEvent: Event) => void; - } - - /** - * Parameters of the StepInput#change event. - */ - export interface StepInput$ChangeEventParameters {} - - /** - * Event object of the StepInput#change event. - */ - export type StepInput$ChangeEvent = Event< - StepInput$ChangeEventParameters, - StepInput - >; -} - -declare module "sap/ui/webc/main/SuggestionGroupItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IInputSuggestionItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.SuggestionGroupItem` is type of suggestion item, that can be used to split the - * `sap.ui.webc.main.Input` suggestions into groups. - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class SuggestionGroupItem - extends WebComponent - implements IInputSuggestionItem - { - __implements__sap_ui_webc_main_IInputSuggestionItem: boolean; - /** - * Constructor for a new `SuggestionGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SuggestionGroupItemSettings - ); - /** - * Constructor for a new `SuggestionGroupItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SuggestionGroupItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.SuggestionGroupItem with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.SuggestionGroupItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the `sap.ui.webc.main.SuggestionGroupItem`. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the `sap.ui.webc.main.SuggestionGroupItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the SuggestionGroupItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $SuggestionGroupItemSettings extends $WebComponentSettings { - /** - * Defines the text of the `sap.ui.webc.main.SuggestionGroupItem`. - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/SuggestionItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IInputSuggestionItem, ListItemType } from "sap/ui/webc/main/library"; - - import { ValueState } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.SuggestionItem` represents the suggestion item of the `sap.ui.webc.main.Input`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class SuggestionItem - extends WebComponent - implements IInputSuggestionItem - { - __implements__sap_ui_webc_main_IInputSuggestionItem: boolean; - /** - * Constructor for a new `SuggestionItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SuggestionItemSettings - ); - /** - * Constructor for a new `SuggestionItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SuggestionItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.SuggestionItem with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.SuggestionItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the item. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * - * Available options are: `"None"` (by default), `"Success"`, `"Information"`, `"Warning"` and `"Error"`. - * - * Default value is `None`. - * - * - * @returns Value of property `additionalTextState` - */ - getAdditionalTextState(): ValueState; - /** - * Gets current value of property {@link #getDescription description}. - * - * Defines the description displayed right under the item text, if such is present. - * - * - * @returns Value of property `description` - */ - getDescription(): string; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIconEnd iconEnd}. - * - * Defines whether the `icon` should be displayed in the beginning of the item or in the end. - * - * **Note:** If `image` is set, the `icon` would be displayed after the `image`. - * - * Default value is `false`. - * - * - * @returns Value of property `iconEnd` - */ - getIconEnd(): boolean; - /** - * Gets current value of property {@link #getImage image}. - * - * Defines the `image` source URI. - * - * **Note:** The `image` would be displayed in the beginning of the item. - * - * - * @returns Value of property `image` - */ - getImage(): string; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the visual indication and behavior of the item. Available options are `Active` (by default), - * `Inactive` and `Detail`. - * - * **Note:** When set to `Active`, the item will provide visual response upon press and hover, while when - * `Inactive` or `Detail` - will not. - * - * Default value is `Active`. - * - * - * @returns Value of property `type` - */ - getType(): ListItemType; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText: string - ): this; - /** - * Sets a new value for property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * - * Available options are: `"None"` (by default), `"Success"`, `"Information"`, `"Warning"` and `"Error"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalTextState( - /** - * New value for property `additionalTextState` - */ - sAdditionalTextState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getDescription description}. - * - * Defines the description displayed right under the item text, if such is present. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDescription( - /** - * New value for property `description` - */ - sDescription: string - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon: string - ): this; - /** - * Sets a new value for property {@link #getIconEnd iconEnd}. - * - * Defines whether the `icon` should be displayed in the beginning of the item or in the end. - * - * **Note:** If `image` is set, the `icon` would be displayed after the `image`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIconEnd( - /** - * New value for property `iconEnd` - */ - bIconEnd?: boolean - ): this; - /** - * Sets a new value for property {@link #getImage image}. - * - * Defines the `image` source URI. - * - * **Note:** The `image` would be displayed in the beginning of the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setImage( - /** - * New value for property `image` - */ - sImage: string - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the visual indication and behavior of the item. Available options are `Active` (by default), - * `Inactive` and `Detail`. - * - * **Note:** When set to `Active`, the item will provide visual response upon press and hover, while when - * `Inactive` or `Detail` - will not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Active`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ListItemType | keyof typeof ListItemType - ): this; - } - /** - * Describes the settings that can be provided to the SuggestionItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SuggestionItemSettings extends $WebComponentSettings { - /** - * Defines the `additionalText`, displayed in the end of the item. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the state of the `additionalText`. - * - * Available options are: `"None"` (by default), `"Success"`, `"Information"`, `"Warning"` and `"Error"`. - */ - additionalTextState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the description displayed right under the item text, if such is present. - */ - description?: string | PropertyBindingInfo; - - /** - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous built-in icons. To find all the available icons, see the - * {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the `icon` should be displayed in the beginning of the item or in the end. - * - * **Note:** If `image` is set, the `icon` would be displayed after the `image`. - */ - iconEnd?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `image` source URI. - * - * **Note:** The `image` would be displayed in the beginning of the item. - */ - image?: string | PropertyBindingInfo; - - /** - * Defines the text of the component. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the visual indication and behavior of the item. Available options are `Active` (by default), - * `Inactive` and `Detail`. - * - * **Note:** When set to `Active`, the item will provide visual response upon press and hover, while when - * `Inactive` or `Detail` - will not. - */ - type?: - | (ListItemType | keyof typeof ListItemType) - | PropertyBindingInfo - | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/Switch" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { SwitchDesign } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.Switch` component is used for changing between binary states. - * The component can display texts, that will be switched, based on the component state, via the `textOn` - * and `textOff` properties, but texts longer than 3 letters will be cutted off. - * However, users are able to customize the width of `sap.ui.webc.main.Switch` with pure CSS (``), and set widths, depending on the texts they would use. - * Note: the component would not automatically stretch to fit the whole text width. - * - * Keyboard Handling: The state can be changed by pressing the Space and Enter keys. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.Switch` exposes the following CSS Shadow Parts: - * - slider - Used to style the track, where the handle is being slid - * - text-on - Used to style the `textOn` property text - * - text-off - Used to style the `textOff` property text - * - handle - Used to style the handle of the switch - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Switch extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `Switch`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $SwitchSettings - ); - /** - * Constructor for a new `Switch`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $SwitchSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Switch with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Switch. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Switch`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Switch` itself. - * - * Fired when the component checked state changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Switch` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.Switch`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Switch` itself. - * - * Fired when the component checked state changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Switch` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.Switch`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Sets the accessible ARIA name of the component. - * - * **Note**: We recommend that you set an accessibleNameRef pointing to an external label or at least an - * `accessibleName`. Providing an `ariaLabelledBy` or an `accessibleName` is mandatory in the cases when - * `textOn` and `textOff` properties aren't set. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getChecked checked}. - * - * Defines if the component is checked. - * - * **Note:** The property can be changed with user interaction, either by cliking the component, or by - * pressing the `Enter` or `Space` key. - * - * Default value is `false`. - * - * - * @returns Value of property `checked` - */ - getChecked(): boolean; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component design. - * - * **Note:** If `Graphical` type is set, positive and negative icons will replace the `textOn` and `textOff`. - * - * Default value is `Textual`. - * - * - * @returns Value of property `design` - */ - getDesign(): SwitchDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getTextOff textOff}. - * - * Defines the text, displayed when the component is not checked. - * - * **Note:** We recommend using short texts, up to 3 letters (larger texts would be cut off). - * - * Default value is `empty string`. - * - * - * @returns Value of property `textOff` - */ - getTextOff(): string; - /** - * Gets current value of property {@link #getTextOn textOn}. - * - * Defines the text, displayed when the component is checked. - * - * - * - * **Note:** We recommend using short texts, up to 3 letters (larger texts would be cut off). - * - * Default value is `empty string`. - * - * - * @returns Value of property `textOn` - */ - getTextOn(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Sets the accessible ARIA name of the component. - * - * **Note**: We recommend that you set an accessibleNameRef pointing to an external label or at least an - * `accessibleName`. Providing an `ariaLabelledBy` or an `accessibleName` is mandatory in the cases when - * `textOn` and `textOff` properties aren't set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getChecked checked}. - * - * Defines if the component is checked. - * - * **Note:** The property can be changed with user interaction, either by cliking the component, or by - * pressing the `Enter` or `Space` key. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setChecked( - /** - * New value for property `checked` - */ - bChecked?: boolean - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component design. - * - * **Note:** If `Graphical` type is set, positive and negative icons will replace the `textOn` and `textOff`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Textual`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: SwitchDesign | keyof typeof SwitchDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getTextOff textOff}. - * - * Defines the text, displayed when the component is not checked. - * - * **Note:** We recommend using short texts, up to 3 letters (larger texts would be cut off). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTextOff( - /** - * New value for property `textOff` - */ - sTextOff?: string - ): this; - /** - * Sets a new value for property {@link #getTextOn textOn}. - * - * Defines the text, displayed when the component is checked. - * - * - * - * **Note:** We recommend using short texts, up to 3 letters (larger texts would be cut off). - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTextOn( - /** - * New value for property `textOn` - */ - sTextOn?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Switch constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $SwitchSettings extends $WebComponentSettings { - /** - * Sets the accessible ARIA name of the component. - * - * **Note**: We recommend that you set an accessibleNameRef pointing to an external label or at least an - * `accessibleName`. Providing an `ariaLabelledBy` or an `accessibleName` is mandatory in the cases when - * `textOn` and `textOff` properties aren't set. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines if the component is checked. - * - * **Note:** The property can be changed with user interaction, either by cliking the component, or by - * pressing the `Enter` or `Space` key. - */ - checked?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the component design. - * - * **Note:** If `Graphical` type is set, positive and negative icons will replace the `textOn` and `textOff`. - */ - design?: - | (SwitchDesign | keyof typeof SwitchDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text, displayed when the component is not checked. - * - * **Note:** We recommend using short texts, up to 3 letters (larger texts would be cut off). - */ - textOff?: string | PropertyBindingInfo; - - /** - * Defines the text, displayed when the component is checked. - * - * - * - * **Note:** We recommend using short texts, up to 3 letters (larger texts would be cut off). - */ - textOn?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component checked state changes. - */ - change?: (oEvent: Event) => void; - } - - /** - * Parameters of the Switch#change event. - */ - export interface Switch$ChangeEventParameters {} - - /** - * Event object of the Switch#change event. - */ - export type Switch$ChangeEvent = Event; -} - -declare module "sap/ui/webc/main/Tab" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITab, SemanticColor } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.Tab` represents a selectable item inside a `sap.ui.webc.main.TabContainer`. It - * defines both the item in the tab strip (top part of the `sap.ui.webc.main.TabContainer`) and the content - * that is presented to the user once the tab is selected. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Tab extends WebComponent implements ITab { - __implements__sap_ui_webc_main_ITab: boolean; - /** - * Constructor for a new `Tab`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TabSettings - ); - /** - * Constructor for a new `Tab`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TabSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Tab with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Tab. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some subTab to the aggregation {@link #getSubTabs subTabs}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addSubTab( - /** - * The subTab to add; if empty, nothing is inserted - */ - oSubTab: ITab - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys all the subTabs in the aggregation {@link #getSubTabs subTabs}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroySubTabs(): this; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Represents the "additionalText" text, which is displayed in the tab. In the cases when in the same time - * there are tabs with icons and tabs without icons, if a tab has no icon the "additionalText" is displayed - * larger. - * - * Default value is `empty string`. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Holds the content associated with this tab. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component's design color. - * - * The design is applied to: - * - the component icon - * - the `text` when the component overflows - * - the tab selection line - * - * - * - * Available designs are: `"Default"`, `"Neutral"`, `"Positive"`, `"Critical"` and `"Negative"`. - * - * - * - * **Note:** The design depends on the current theme. - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): SemanticColor; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon source URI to be displayed as graphical element within the component. The SAP-icons - * font provides numerous built-in icons. See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Specifies if the component is selected. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets content of aggregation {@link #getSubTabs subTabs}. - * - * Defines hierarchies with nested sub tabs. - * - * **Note:** Use `sap.ui.webc.main.Tab` and `sap.ui.webc.main.TabSeparator` for the intended design. - */ - getSubTabs(): ITab[]; - /** - * Returns the DOM reference of the tab that is placed in the header. **Note:** Tabs, placed in the `subTabs` - * slot of other tabs are not shown in the header. Calling this method on such tabs will return `null`. - * **Note:** If you need a DOM ref to the tab content please use the `getDomRef` method. - */ - getTabInStripDomRef(): void; - /** - * Gets current value of property {@link #getText text}. - * - * The text to be displayed for the item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.main.ITab` in the aggregation {@link #getSubTabs subTabs}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfSubTab( - /** - * The subTab whose index is looked for - */ - oSubTab: ITab - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a subTab into the aggregation {@link #getSubTabs subTabs}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertSubTab( - /** - * The subTab to insert; if empty, nothing is inserted - */ - oSubTab: ITab, - /** - * The `0`-based index the subTab should be inserted at; for a negative value of `iIndex`, the subTab is - * inserted at position 0; for a value greater than the current size of the aggregation, the subTab is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getSubTabs subTabs}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllSubTabs(): ITab[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a subTab from the aggregation {@link #getSubTabs subTabs}. - * - * - * @returns The removed subTab or `null` - */ - removeSubTab( - /** - * The subTab to remove or its index or id - */ - vSubTab: int | string | ITab - ): ITab | null; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Represents the "additionalText" text, which is displayed in the tab. In the cases when in the same time - * there are tabs with icons and tabs without icons, if a tab has no icon the "additionalText" is displayed - * larger. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText?: string - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component's design color. - * - * The design is applied to: - * - the component icon - * - the `text` when the component overflows - * - the tab selection line - * - * - * - * Available designs are: `"Default"`, `"Neutral"`, `"Positive"`, `"Critical"` and `"Negative"`. - * - * - * - * **Note:** The design depends on the current theme. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: SemanticColor | keyof typeof SemanticColor - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon source URI to be displayed as graphical element within the component. The SAP-icons - * font provides numerous built-in icons. See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Specifies if the component is selected. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * The text to be displayed for the item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the Tab constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TabSettings extends $WebComponentSettings { - /** - * Represents the "additionalText" text, which is displayed in the tab. In the cases when in the same time - * there are tabs with icons and tabs without icons, if a tab has no icon the "additionalText" is displayed - * larger. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the component's design color. - * - * The design is applied to: - * - the component icon - * - the `text` when the component overflows - * - the tab selection line - * - * - * - * Available designs are: `"Default"`, `"Neutral"`, `"Positive"`, `"Critical"` and `"Negative"`. - * - * - * - * **Note:** The design depends on the current theme. - */ - design?: - | (SemanticColor | keyof typeof SemanticColor) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon source URI to be displayed as graphical element within the component. The SAP-icons - * font provides numerous built-in icons. See all the available icons in the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Specifies if the component is selected. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * The text to be displayed for the item. - */ - text?: string | PropertyBindingInfo; - - /** - * Holds the content associated with this tab. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines hierarchies with nested sub tabs. - * - * **Note:** Use `sap.ui.webc.main.Tab` and `sap.ui.webc.main.TabSeparator` for the intended design. - */ - subTabs?: ITab[] | ITab | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/TabContainer" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - ITab, - TabContainerBackgroundDesign, - IButton, - TabLayout, - TabsOverflowMode, - } from "sap/ui/webc/main/library"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: - * - * The `sap.ui.webc.main.TabContainer` represents a collection of tabs with associated content. Navigation - * through the tabs changes the content display of the currently active content area. A tab can be labeled - * with text only, or icons with text. - * - * Structure: - * - * The `sap.ui.webc.main.TabContainer` can hold two types of entities: - * - `sap.ui.webc.main.Tab` - contains all the information on an item (text and icon) - * - `sap.ui.webc.main.TabSeparator` - used to separate tabs with a line - * - * Hierarchies: Multiple sub tabs could be placed underneath one main tab. Nesting allows deeper hierarchies - * with indentations to indicate the level of each nested tab. When a tab has both sub tabs and own content - * its click area is split to allow the user to display the content or alternatively to expand / collapse - * the list of sub tabs. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TabContainer` exposes the following CSS Shadow Parts: - * - content - Used to style the content of the component - * - * Keyboard Handling: - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TabContainer extends WebComponent { - /** - * Constructor for a new `TabContainer`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TabContainerSettings - ); - /** - * Constructor for a new `TabContainer`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TabContainerSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TabContainer with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TabContainer. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ITab - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:tabSelect tabSelect} event of this `sap.ui.webc.main.TabContainer`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TabContainer` itself. - * - * Fired when a tab is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachTabSelect( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: TabContainer$TabSelectEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TabContainer` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:tabSelect tabSelect} event of this `sap.ui.webc.main.TabContainer`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TabContainer` itself. - * - * Fired when a tab is selected. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachTabSelect( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: TabContainer$TabSelectEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TabContainer` itself - */ - oListener?: object - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Destroys the overflowButton in the aggregation {@link #getOverflowButton overflowButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyOverflowButton(): this; - /** - * Destroys the startOverflowButton in the aggregation {@link #getStartOverflowButton startOverflowButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyStartOverflowButton(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:tabSelect tabSelect} event of this `sap.ui.webc.main.TabContainer`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachTabSelect( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: TabContainer$TabSelectEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:tabSelect tabSelect} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireTabSelect( - /** - * Parameters to pass along with the event - */ - mParameters?: TabContainer$TabSelectEventParameters - ): boolean; - /** - * Returns all slotted tabs and their subTabs in a flattened array. The order of tabs is depth-first. For - * example, given the following slotted elements: - * ```javascript - * - * - * - * ... - * ... - * - * ... - * - * ... - * - * ``` - * Calling `allItems` on this TabContainer will return the instances in the following order: `[ ui5-tab#First, - * ui5-tab#Nested, ui5-tab#Second, ui5-tab-separator#sep, ui5-tab#Third ]` - */ - getAllItems(): void; - /** - * Gets current value of property {@link #getCollapsed collapsed}. - * - * Defines whether the tab content is collapsed. - * - * Default value is `false`. - * - * - * @returns Value of property `collapsed` - */ - getCollapsed(): boolean; - /** - * Gets current value of property {@link #getContentBackgroundDesign contentBackgroundDesign}. - * - * Sets the background color of the Tab Container's content as `Solid`, `Transparent`, or `Translucent`. - * - * Default value is `Solid`. - * - * - * @returns Value of property `contentBackgroundDesign` - */ - getContentBackgroundDesign(): TabContainerBackgroundDesign; - /** - * Gets current value of property {@link #getFixed fixed}. - * - * Defines whether the tabs are in a fixed state that is not expandable/collapsible by user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `fixed` - */ - getFixed(): boolean; - /** - * Gets current value of property {@link #getHeaderBackgroundDesign headerBackgroundDesign}. - * - * Sets the background color of the Tab Container's header as `Solid`, `Transparent`, or `Translucent`. - * - * Default value is `Solid`. - * - * - * @returns Value of property `headerBackgroundDesign` - */ - getHeaderBackgroundDesign(): TabContainerBackgroundDesign; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the tabs. - * - * **Note:** Use `sap.ui.webc.main.Tab` and `sap.ui.webc.main.TabSeparator` for the intended design. - */ - getItems(): ITab[]; - /** - * Gets content of aggregation {@link #getOverflowButton overflowButton}. - * - * Defines the button which will open the overflow menu. If nothing is provided to this slot, the default - * button will be used. - */ - getOverflowButton(): IButton; - /** - * Gets content of aggregation {@link #getStartOverflowButton startOverflowButton}. - * - * Defines the button which will open the start overflow menu if available. If nothing is provided to this - * slot, the default button will be used. - */ - getStartOverflowButton(): IButton; - /** - * Gets current value of property {@link #getTabLayout tabLayout}. - * - * Defines the alignment of the content and the `additionalText` of a tab. - * - * - * **Note:** The content and the `additionalText` would be displayed vertically by default, but when set - * to `Inline`, they would be displayed horizontally. - * - * Default value is `Standard`. - * - * - * @returns Value of property `tabLayout` - */ - getTabLayout(): TabLayout; - /** - * Gets current value of property {@link #getTabsOverflowMode tabsOverflowMode}. - * - * Defines the overflow mode of the header (the tab strip). If you have a large number of tabs, only the - * tabs that can fit on screen will be visible. All other tabs that can 't fit on the screen are available - * in an overflow tab "More". - * - * - * **Note:** Only one overflow at the end would be displayed by default, but when set to `StartAndEnd`, - * there will be two overflows on both ends, and tab order will not change on tab selection. - * - * Default value is `End`. - * - * - * @returns Value of property `tabsOverflowMode` - */ - getTabsOverflowMode(): TabsOverflowMode; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.ITab` in the aggregation {@link #getItems items}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ITab - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ITab, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ITab[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ITab - ): ITab | null; - /** - * Sets a new value for property {@link #getCollapsed collapsed}. - * - * Defines whether the tab content is collapsed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setCollapsed( - /** - * New value for property `collapsed` - */ - bCollapsed?: boolean - ): this; - /** - * Sets a new value for property {@link #getContentBackgroundDesign contentBackgroundDesign}. - * - * Sets the background color of the Tab Container's content as `Solid`, `Transparent`, or `Translucent`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Solid`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setContentBackgroundDesign( - /** - * New value for property `contentBackgroundDesign` - */ - sContentBackgroundDesign?: - | TabContainerBackgroundDesign - | keyof typeof TabContainerBackgroundDesign - ): this; - /** - * Sets a new value for property {@link #getFixed fixed}. - * - * Defines whether the tabs are in a fixed state that is not expandable/collapsible by user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFixed( - /** - * New value for property `fixed` - */ - bFixed?: boolean - ): this; - /** - * Sets a new value for property {@link #getHeaderBackgroundDesign headerBackgroundDesign}. - * - * Sets the background color of the Tab Container's header as `Solid`, `Transparent`, or `Translucent`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Solid`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderBackgroundDesign( - /** - * New value for property `headerBackgroundDesign` - */ - sHeaderBackgroundDesign?: - | TabContainerBackgroundDesign - | keyof typeof TabContainerBackgroundDesign - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets the aggregated {@link #getOverflowButton overflowButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setOverflowButton( - /** - * The overflowButton to set - */ - oOverflowButton: IButton - ): this; - /** - * Sets the aggregated {@link #getStartOverflowButton startOverflowButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStartOverflowButton( - /** - * The startOverflowButton to set - */ - oStartOverflowButton: IButton - ): this; - /** - * Sets a new value for property {@link #getTabLayout tabLayout}. - * - * Defines the alignment of the content and the `additionalText` of a tab. - * - * - * **Note:** The content and the `additionalText` would be displayed vertically by default, but when set - * to `Inline`, they would be displayed horizontally. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Standard`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTabLayout( - /** - * New value for property `tabLayout` - */ - sTabLayout?: TabLayout | keyof typeof TabLayout - ): this; - /** - * Sets a new value for property {@link #getTabsOverflowMode tabsOverflowMode}. - * - * Defines the overflow mode of the header (the tab strip). If you have a large number of tabs, only the - * tabs that can fit on screen will be visible. All other tabs that can 't fit on the screen are available - * in an overflow tab "More". - * - * - * **Note:** Only one overflow at the end would be displayed by default, but when set to `StartAndEnd`, - * there will be two overflows on both ends, and tab order will not change on tab selection. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `End`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setTabsOverflowMode( - /** - * New value for property `tabsOverflowMode` - */ - sTabsOverflowMode?: TabsOverflowMode | keyof typeof TabsOverflowMode - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the TabContainer constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TabContainerSettings extends $WebComponentSettings { - /** - * Defines whether the tab content is collapsed. - */ - collapsed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Sets the background color of the Tab Container's content as `Solid`, `Transparent`, or `Translucent`. - */ - contentBackgroundDesign?: - | ( - | TabContainerBackgroundDesign - | keyof typeof TabContainerBackgroundDesign - ) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the tabs are in a fixed state that is not expandable/collapsible by user interaction. - */ - fixed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Sets the background color of the Tab Container's header as `Solid`, `Transparent`, or `Translucent`. - */ - headerBackgroundDesign?: - | ( - | TabContainerBackgroundDesign - | keyof typeof TabContainerBackgroundDesign - ) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the alignment of the content and the `additionalText` of a tab. - * - * - * **Note:** The content and the `additionalText` would be displayed vertically by default, but when set - * to `Inline`, they would be displayed horizontally. - */ - tabLayout?: - | (TabLayout | keyof typeof TabLayout) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the overflow mode of the header (the tab strip). If you have a large number of tabs, only the - * tabs that can fit on screen will be visible. All other tabs that can 't fit on the screen are available - * in an overflow tab "More". - * - * - * **Note:** Only one overflow at the end would be displayed by default, but when set to `StartAndEnd`, - * there will be two overflows on both ends, and tab order will not change on tab selection. - */ - tabsOverflowMode?: - | (TabsOverflowMode | keyof typeof TabsOverflowMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the tabs. - * - * **Note:** Use `sap.ui.webc.main.Tab` and `sap.ui.webc.main.TabSeparator` for the intended design. - */ - items?: ITab[] | ITab | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the button which will open the overflow menu. If nothing is provided to this slot, the default - * button will be used. - */ - overflowButton?: IButton; - - /** - * Defines the button which will open the start overflow menu if available. If nothing is provided to this - * slot, the default button will be used. - */ - startOverflowButton?: IButton; - - /** - * Fired when a tab is selected. - */ - tabSelect?: (oEvent: TabContainer$TabSelectEvent) => void; - } - - /** - * Parameters of the TabContainer#tabSelect event. - */ - export interface TabContainer$TabSelectEventParameters { - /** - * The selected `tab`. - */ - tab?: HTMLElement; - - /** - * The selected `tab` index in the flattened array of all tabs and their subTabs, provided by the `allItems` - * getter. - */ - tabIndex?: int; - } - - /** - * Event object of the TabContainer#tabSelect event. - */ - export type TabContainer$TabSelectEvent = Event< - TabContainer$TabSelectEventParameters, - TabContainer - >; -} - -declare module "sap/ui/webc/main/Table" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { - ITableColumn, - ITableRow, - TableGrowingMode, - TableMode, - } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Table` component provides a set of sophisticated and convenient functions for responsive - * table design. It provides a comprehensive set of features for displaying and dealing with vast amounts - * of data. - * - * To render the `Table` properly, the order of the `columns` should match with the order of the item `cells` - * in the `rows`. - * - * Desktop and tablet devices are supported. On tablets, special consideration should be given to the number - * of visible columns and rows due to the limited performance of some devices. - * - * Selection: To benefit from the selection mechanism of `sap.ui.webc.main.Table` component, you can use - * the available selection modes: `SingleSelect` and `MultiSelect`. - * In additition to the used mode, you can also specify the `sap.ui.webc.main.TableRow` type choosing between - * `Active` or `Inactive`. - * - * In `SingleSelect` mode, you can select both an `Active` and `Inactive` row via mouse or by pressing - * the `Space` or `Enter` keys. - * In `MultiSelect` mode, you can select both an `Active` and `Inactive` row by pressing the `Space` key - * when a row is on focus or via mouse click over the selection checkbox of the row. In order to select - * all the available rows at once, you can use the selection checkbox presented in the table's header. - * - * **Note:** Currently, when a column is shown as a pop-in, the visual indication for selection is not - * presented over it. - * - * Keyboard Handling: - * - * - * - [F7] - If focus is on an interactive control inside an item, moves focus to the corresponding item. - * - * - [CTRL]+[A] - Selects all items, if MultiSelect mode is enabled. - * - [HOME]/[END] - Focuses the first/last item. - * - [PAGEUP]/[PAGEDOWN] - Moves focus up/down by page size (20 items by default). - * - [ALT]+[DOWN]/[UP] - Switches focus between header, last focused item, and More button (if applies) - * in either direction. - * - [SHIFT]+[DOWN]/[UP] - Selects the next/previous item in a MultiSelect table, if the current item - * is selected (Range selection). Otherwise, deselects them (Range deselection). - * - [SHIFT]+[HOME]/[END] - Range selection to the first/last item of the List. - * - [CTRL]+[HOME]/[END] - Same behavior as HOME & END. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Table extends WebComponent { - /** - * Constructor for a new `Table`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TableSettings - ); - /** - * Constructor for a new `Table`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TableSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Table with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Table. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some column to the aggregation {@link #getColumns columns}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addColumn( - /** - * The column to add; if empty, nothing is inserted - */ - oColumn: ITableColumn - ): this; - /** - * Adds some row to the aggregation {@link #getRows rows}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addRow( - /** - * The row to add; if empty, nothing is inserted - */ - oRow: ITableRow - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:loadMore loadMore} event of this `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when the user presses the `More` button or scrolls to the table's end. - * - * - * - * **Note:** The event will be fired if `growing` is set to `Button` or `Scroll`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLoadMore( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:loadMore loadMore} event of this `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when the user presses the `More` button or scrolls to the table's end. - * - * - * - * **Note:** The event will be fired if `growing` is set to `Button` or `Scroll`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachLoadMore( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:popinChange popinChange} event of this `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when `sap.ui.webc.main.TableColumn` is shown as a pop-in instead of hiding it. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachPopinChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Table$PopinChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:popinChange popinChange} event of this `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when `sap.ui.webc.main.TableColumn` is shown as a pop-in instead of hiding it. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachPopinChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Table$PopinChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:rowClick rowClick} event of this `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when a row in `Active` mode is clicked or `Enter` key is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachRowClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Table$RowClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:rowClick rowClick} event of this `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when a row in `Active` mode is clicked or `Enter` key is pressed. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachRowClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Table$RowClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Table$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.Table`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Table` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Table$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Table` itself - */ - oListener?: object - ): this; - /** - * Destroys all the columns in the aggregation {@link #getColumns columns}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyColumns(): this; - /** - * Destroys all the rows in the aggregation {@link #getRows rows}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyRows(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:loadMore loadMore} event of this `sap.ui.webc.main.Table`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachLoadMore( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:popinChange popinChange} event of this `sap.ui.webc.main.Table`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachPopinChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Table$PopinChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:rowClick rowClick} event of this `sap.ui.webc.main.Table`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachRowClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Table$RowClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.main.Table`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Table$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:loadMore loadMore} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireLoadMore( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:popinChange popinChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - firePopinChange( - /** - * Parameters to pass along with the event - */ - mParameters?: Table$PopinChangeEventParameters - ): this; - /** - * Fires event {@link #event:rowClick rowClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireRowClick( - /** - * Parameters to pass along with the event - */ - mParameters?: Table$RowClickEventParameters - ): this; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: Table$SelectionChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getBusy busy}. - * - * Defines if the table is in busy state. - * - * In this state the component's opacity is reduced and busy indicator is displayed at the bottom of the - * table. - * - * Default value is `false`. - * - * - * @returns Value of property `busy` - */ - getBusy(): boolean; - /** - * Gets current value of property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * Default value is `1000`. - * - * - * @returns Value of property `busyDelay` - */ - getBusyDelay(): int; - /** - * Gets content of aggregation {@link #getColumns columns}. - * - * Defines the configuration for the columns of the component. - * - * **Note:** Use `sap.ui.webc.main.TableColumn` for the intended design. - */ - getColumns(): ITableColumn[]; - /** - * Gets current value of property {@link #getGrowing growing}. - * - * Defines whether the table will have growing capability either by pressing a `More` button, or via user - * scroll. In both cases `load-more` event is fired. - * - * - * - * Available options: - * - * `Button` - Shows a `More` button at the bottom of the table, pressing of which triggers the `load-more` - * event. - * `Scroll` - The `load-more` event is triggered when the user scrolls to the bottom of the table; - * `None` (default) - The growing is off. - * - * - * - * **Restrictions:** `growing="Scroll"` is not supported for Internet Explorer, and the component will fallback - * to `growing="Button"`. - * - * Default value is `None`. - * - * - * @returns Value of property `growing` - */ - getGrowing(): TableGrowingMode; - /** - * Gets current value of property {@link #getGrowingButtonSubtext growingButtonSubtext}. - * - * Defines the subtext that will be displayed under the `growingButtonText`. - * - * - * - * **Note:** This property takes effect if `growing` is set to `Button`. - * - * Default value is `empty string`. - * - * - * @returns Value of property `growingButtonSubtext` - */ - getGrowingButtonSubtext(): string; - /** - * Gets current value of property {@link #getGrowingButtonText growingButtonText}. - * - * Defines the text that will be displayed inside the growing button at the bottom of the table, meant for - * loading more rows upon press. - * - * - * - * **Note:** If not specified a built-in text will be displayed. - * **Note:** This property takes effect if `growing` is set to `Button`. - * - * Default value is `empty string`. - * - * - * @returns Value of property `growingButtonText` - */ - getGrowingButtonText(): string; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getHideNoData hideNoData}. - * - * Defines if the value of `noDataText` will be diplayed when there is no rows present in the table. - * - * Default value is `false`. - * - * - * @returns Value of property `hideNoData` - */ - getHideNoData(): boolean; - /** - * Gets current value of property {@link #getMode mode}. - * - * Defines the mode of the component. - * - * Default value is `None`. - * - * - * @returns Value of property `mode` - */ - getMode(): TableMode; - /** - * Gets current value of property {@link #getNoDataText noDataText}. - * - * Defines the text that will be displayed when there is no data and `hideNoData` is not present. - * - * Default value is `empty string`. - * - * - * @returns Value of property `noDataText` - */ - getNoDataText(): string; - /** - * Gets content of aggregation {@link #getRows rows}. - * - * Defines the component rows. - * - * **Note:** Use `sap.ui.webc.main.TableRow` for the intended design. - */ - getRows(): ITableRow[]; - /** - * Gets current value of property {@link #getStickyColumnHeader stickyColumnHeader}. - * - * Determines whether the column headers remain fixed at the top of the page during vertical scrolling as - * long as the Web Component is in the viewport. - * - * **Restrictions:** - * - Browsers that do not support this feature: - * Internet Explorer - * - Microsoft Edge lower than version 41 (EdgeHTML 16) - * - Mozilla Firefox lower than version 59 - * - Scrolling behavior: - * If the Web Component is placed in layout containers that have the `overflow: hidden` or `overflow: auto` - * style definition, this can prevent the sticky elements of the Web Component from becoming fixed at the - * top of the viewport. - * - * Default value is `false`. - * - * - * @returns Value of property `stickyColumnHeader` - */ - getStickyColumnHeader(): boolean; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.ITableColumn` in the aggregation {@link #getColumns columns}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfColumn( - /** - * The column whose index is looked for - */ - oColumn: ITableColumn - ): int; - /** - * Checks for the provided `sap.ui.webc.main.ITableRow` in the aggregation {@link #getRows rows}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfRow( - /** - * The row whose index is looked for - */ - oRow: ITableRow - ): int; - /** - * Inserts a column into the aggregation {@link #getColumns columns}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertColumn( - /** - * The column to insert; if empty, nothing is inserted - */ - oColumn: ITableColumn, - /** - * The `0`-based index the column should be inserted at; for a negative value of `iIndex`, the column is - * inserted at position 0; for a value greater than the current size of the aggregation, the column is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a row into the aggregation {@link #getRows rows}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertRow( - /** - * The row to insert; if empty, nothing is inserted - */ - oRow: ITableRow, - /** - * The `0`-based index the row should be inserted at; for a negative value of `iIndex`, the row is inserted - * at position 0; for a value greater than the current size of the aggregation, the row is inserted at the - * last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getColumns columns}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllColumns(): ITableColumn[]; - /** - * Removes all the controls from the aggregation {@link #getRows rows}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllRows(): ITableRow[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a column from the aggregation {@link #getColumns columns}. - * - * - * @returns The removed column or `null` - */ - removeColumn( - /** - * The column to remove or its index or id - */ - vColumn: int | string | ITableColumn - ): ITableColumn | null; - /** - * Removes a row from the aggregation {@link #getRows rows}. - * - * - * @returns The removed row or `null` - */ - removeRow( - /** - * The row to remove or its index or id - */ - vRow: int | string | ITableRow - ): ITableRow | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getBusy busy}. - * - * Defines if the table is in busy state. - * - * In this state the component's opacity is reduced and busy indicator is displayed at the bottom of the - * table. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusy( - /** - * New value for property `busy` - */ - bBusy?: boolean - ): this; - /** - * Sets a new value for property {@link #getBusyDelay busyDelay}. - * - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `1000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setBusyDelay( - /** - * New value for property `busyDelay` - */ - iBusyDelay?: int - ): this; - /** - * Sets a new value for property {@link #getGrowing growing}. - * - * Defines whether the table will have growing capability either by pressing a `More` button, or via user - * scroll. In both cases `load-more` event is fired. - * - * - * - * Available options: - * - * `Button` - Shows a `More` button at the bottom of the table, pressing of which triggers the `load-more` - * event. - * `Scroll` - The `load-more` event is triggered when the user scrolls to the bottom of the table; - * `None` (default) - The growing is off. - * - * - * - * **Restrictions:** `growing="Scroll"` is not supported for Internet Explorer, and the component will fallback - * to `growing="Button"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setGrowing( - /** - * New value for property `growing` - */ - sGrowing?: TableGrowingMode | keyof typeof TableGrowingMode - ): this; - /** - * Sets a new value for property {@link #getGrowingButtonSubtext growingButtonSubtext}. - * - * Defines the subtext that will be displayed under the `growingButtonText`. - * - * - * - * **Note:** This property takes effect if `growing` is set to `Button`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setGrowingButtonSubtext( - /** - * New value for property `growingButtonSubtext` - */ - sGrowingButtonSubtext?: string - ): this; - /** - * Sets a new value for property {@link #getGrowingButtonText growingButtonText}. - * - * Defines the text that will be displayed inside the growing button at the bottom of the table, meant for - * loading more rows upon press. - * - * - * - * **Note:** If not specified a built-in text will be displayed. - * **Note:** This property takes effect if `growing` is set to `Button`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setGrowingButtonText( - /** - * New value for property `growingButtonText` - */ - sGrowingButtonText?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getHideNoData hideNoData}. - * - * Defines if the value of `noDataText` will be diplayed when there is no rows present in the table. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideNoData( - /** - * New value for property `hideNoData` - */ - bHideNoData?: boolean - ): this; - /** - * Sets a new value for property {@link #getMode mode}. - * - * Defines the mode of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMode( - /** - * New value for property `mode` - */ - sMode?: TableMode | keyof typeof TableMode - ): this; - /** - * Sets a new value for property {@link #getNoDataText noDataText}. - * - * Defines the text that will be displayed when there is no data and `hideNoData` is not present. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoDataText( - /** - * New value for property `noDataText` - */ - sNoDataText?: string - ): this; - /** - * Sets a new value for property {@link #getStickyColumnHeader stickyColumnHeader}. - * - * Determines whether the column headers remain fixed at the top of the page during vertical scrolling as - * long as the Web Component is in the viewport. - * - * **Restrictions:** - * - Browsers that do not support this feature: - * Internet Explorer - * - Microsoft Edge lower than version 41 (EdgeHTML 16) - * - Mozilla Firefox lower than version 59 - * - Scrolling behavior: - * If the Web Component is placed in layout containers that have the `overflow: hidden` or `overflow: auto` - * style definition, this can prevent the sticky elements of the Web Component from becoming fixed at the - * top of the viewport. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setStickyColumnHeader( - /** - * New value for property `stickyColumnHeader` - */ - bStickyColumnHeader?: boolean - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the Table constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TableSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines if the table is in busy state. - * - * In this state the component's opacity is reduced and busy indicator is displayed at the bottom of the - * table. - */ - busy?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the delay in milliseconds, after which the busy indicator will show up for this component. - */ - busyDelay?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the table will have growing capability either by pressing a `More` button, or via user - * scroll. In both cases `load-more` event is fired. - * - * - * - * Available options: - * - * `Button` - Shows a `More` button at the bottom of the table, pressing of which triggers the `load-more` - * event. - * `Scroll` - The `load-more` event is triggered when the user scrolls to the bottom of the table; - * `None` (default) - The growing is off. - * - * - * - * **Restrictions:** `growing="Scroll"` is not supported for Internet Explorer, and the component will fallback - * to `growing="Button"`. - */ - growing?: - | (TableGrowingMode | keyof typeof TableGrowingMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the subtext that will be displayed under the `growingButtonText`. - * - * - * - * **Note:** This property takes effect if `growing` is set to `Button`. - */ - growingButtonSubtext?: string | PropertyBindingInfo; - - /** - * Defines the text that will be displayed inside the growing button at the bottom of the table, meant for - * loading more rows upon press. - * - * - * - * **Note:** If not specified a built-in text will be displayed. - * **Note:** This property takes effect if `growing` is set to `Button`. - */ - growingButtonText?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines if the value of `noDataText` will be diplayed when there is no rows present in the table. - */ - hideNoData?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the mode of the component. - */ - mode?: - | (TableMode | keyof typeof TableMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the text that will be displayed when there is no data and `hideNoData` is not present. - */ - noDataText?: string | PropertyBindingInfo; - - /** - * Determines whether the column headers remain fixed at the top of the page during vertical scrolling as - * long as the Web Component is in the viewport. - * - * **Restrictions:** - * - Browsers that do not support this feature: - * Internet Explorer - * - Microsoft Edge lower than version 41 (EdgeHTML 16) - * - Mozilla Firefox lower than version 59 - * - Scrolling behavior: - * If the Web Component is placed in layout containers that have the `overflow: hidden` or `overflow: auto` - * style definition, this can prevent the sticky elements of the Web Component from becoming fixed at the - * top of the viewport. - */ - stickyColumnHeader?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the configuration for the columns of the component. - * - * **Note:** Use `sap.ui.webc.main.TableColumn` for the intended design. - */ - columns?: - | ITableColumn[] - | ITableColumn - | AggregationBindingInfo - | `{${string}}`; - - /** - * Defines the component rows. - * - * **Note:** Use `sap.ui.webc.main.TableRow` for the intended design. - */ - rows?: ITableRow[] | ITableRow | AggregationBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the user presses the `More` button or scrolls to the table's end. - * - * - * - * **Note:** The event will be fired if `growing` is set to `Button` or `Scroll`. - */ - loadMore?: (oEvent: Event) => void; - - /** - * Fired when `sap.ui.webc.main.TableColumn` is shown as a pop-in instead of hiding it. - */ - popinChange?: (oEvent: Table$PopinChangeEvent) => void; - - /** - * Fired when a row in `Active` mode is clicked or `Enter` key is pressed. - */ - rowClick?: (oEvent: Table$RowClickEvent) => void; - - /** - * Fired when selection is changed by user interaction in `SingleSelect` and `MultiSelect` modes. - */ - selectionChange?: (oEvent: Table$SelectionChangeEvent) => void; - } - - /** - * Parameters of the Table#loadMore event. - */ - export interface Table$LoadMoreEventParameters {} - - /** - * Event object of the Table#loadMore event. - */ - export type Table$LoadMoreEvent = Event; - - /** - * Parameters of the Table#popinChange event. - */ - export interface Table$PopinChangeEventParameters { - /** - * popped-in columns. - */ - poppedColumns?: any[]; - } - - /** - * Event object of the Table#popinChange event. - */ - export type Table$PopinChangeEvent = Event< - Table$PopinChangeEventParameters, - Table - >; - - /** - * Parameters of the Table#rowClick event. - */ - export interface Table$RowClickEventParameters { - /** - * the activated row. - */ - row?: HTMLElement; - } - - /** - * Event object of the Table#rowClick event. - */ - export type Table$RowClickEvent = Event; - - /** - * Parameters of the Table#selectionChange event. - */ - export interface Table$SelectionChangeEventParameters { - /** - * An array of the selected rows. - */ - selectedRows?: any[]; - - /** - * An array of the previously selected rows. - */ - previouslySelectedRows?: any[]; - } - - /** - * Event object of the Table#selectionChange event. - */ - export type Table$SelectionChangeEvent = Event< - Table$SelectionChangeEventParameters, - Table - >; -} - -declare module "sap/ui/webc/main/TableCell" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITableCell } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { AggregationBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.TableCell` component defines the structure of the data in a single `sap.ui.webc.main.Table` - * cell. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TableCell` exposes the following CSS Shadow Parts: - * - cell - Used to style the native `td` element - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TableCell extends WebComponent implements ITableCell { - __implements__sap_ui_webc_main_ITableCell: boolean; - /** - * Constructor for a new `TableCell`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TableCellSettings - ); - /** - * Constructor for a new `TableCell`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TableCellSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TableCell with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TableCell. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Specifies the content of the component. - */ - getContent(): Control[]; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - } - /** - * Describes the settings that can be provided to the TableCell constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TableCellSettings extends $WebComponentSettings { - /** - * Specifies the content of the component. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/TableColumn" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - ITableColumn, - TableColumnPopinDisplay, - } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.TableColumn` component allows to define column specific properties that are applied - * when rendering the `sap.ui.webc.main.Table` component. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TableColumn` exposes the following CSS Shadow Parts: - * - column - Used to style the native `th` element - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TableColumn - extends WebComponent - implements ITableColumn - { - __implements__sap_ui_webc_main_ITableColumn: boolean; - /** - * Constructor for a new `TableColumn`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TableColumnSettings - ); - /** - * Constructor for a new `TableColumn`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TableColumnSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TableColumn with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TableColumn. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the column header. - */ - getContent(): Control[]; - /** - * Gets current value of property {@link #getDemandPopin demandPopin}. - * - * According to your `minWidth` settings, the component can be hidden in different screen sizes. - * - * Setting this property to `true`, shows this column as pop-in instead of hiding it. - * - * Default value is `false`. - * - * - * @returns Value of property `demandPopin` - */ - getDemandPopin(): boolean; - /** - * Gets current value of property {@link #getMinWidth minWidth}. - * - * Defines the minimum table width required to display this column. By default it is always displayed. - * - * The responsive behavior of the `sap.ui.webc.main.Table` is determined by this property. As an example, - * by setting `minWidth` property to `400` sets the minimum width to 400 pixels, and shows this column on - * tablet (and desktop) but hides it on mobile. - * For further responsive design options, see `demandPopin` property. - * - * Default value is `...see text or source`. - * - * - * @returns Value of property `minWidth` - */ - getMinWidth(): int; - /** - * Gets current value of property {@link #getPopinDisplay popinDisplay}. - * - * Defines how the popin row is displayed. - * - * - * - * **The available values are:** - * - * - * - `Block` - * - `Inline` - * - * Default value is `Block`. - * - * - * @returns Value of property `popinDisplay` - */ - getPopinDisplay(): TableColumnPopinDisplay; - /** - * Gets current value of property {@link #getPopinText popinText}. - * - * The text for the column when it pops in. - * - * Default value is `empty string`. - * - * - * @returns Value of property `popinText` - */ - getPopinText(): string; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Sets a new value for property {@link #getDemandPopin demandPopin}. - * - * According to your `minWidth` settings, the component can be hidden in different screen sizes. - * - * Setting this property to `true`, shows this column as pop-in instead of hiding it. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDemandPopin( - /** - * New value for property `demandPopin` - */ - bDemandPopin?: boolean - ): this; - /** - * Sets a new value for property {@link #getMinWidth minWidth}. - * - * Defines the minimum table width required to display this column. By default it is always displayed. - * - * The responsive behavior of the `sap.ui.webc.main.Table` is determined by this property. As an example, - * by setting `minWidth` property to `400` sets the minimum width to 400 pixels, and shows this column on - * tablet (and desktop) but hides it on mobile. - * For further responsive design options, see `demandPopin` property. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `...see text or source`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMinWidth( - /** - * New value for property `minWidth` - */ - iMinWidth?: int - ): this; - /** - * Sets a new value for property {@link #getPopinDisplay popinDisplay}. - * - * Defines how the popin row is displayed. - * - * - * - * **The available values are:** - * - * - * - `Block` - * - `Inline` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Block`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPopinDisplay( - /** - * New value for property `popinDisplay` - */ - sPopinDisplay?: - | TableColumnPopinDisplay - | keyof typeof TableColumnPopinDisplay - ): this; - /** - * Sets a new value for property {@link #getPopinText popinText}. - * - * The text for the column when it pops in. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPopinText( - /** - * New value for property `popinText` - */ - sPopinText?: string - ): this; - } - /** - * Describes the settings that can be provided to the TableColumn constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TableColumnSettings extends $WebComponentSettings { - /** - * According to your `minWidth` settings, the component can be hidden in different screen sizes. - * - * Setting this property to `true`, shows this column as pop-in instead of hiding it. - */ - demandPopin?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the minimum table width required to display this column. By default it is always displayed. - * - * The responsive behavior of the `sap.ui.webc.main.Table` is determined by this property. As an example, - * by setting `minWidth` property to `400` sets the minimum width to 400 pixels, and shows this column on - * tablet (and desktop) but hides it on mobile. - * For further responsive design options, see `demandPopin` property. - */ - minWidth?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines how the popin row is displayed. - * - * - * - * **The available values are:** - * - * - * - `Block` - * - `Inline` - */ - popinDisplay?: - | (TableColumnPopinDisplay | keyof typeof TableColumnPopinDisplay) - | PropertyBindingInfo - | `{${string}}`; - - /** - * The text for the column when it pops in. - */ - popinText?: string | PropertyBindingInfo; - - /** - * Defines the content of the column header. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/TableGroupRow" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITableRow } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.TableGroupRow` component represents a group row in the `sap.ui.webc.main.Table`. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TableGroupRow` exposes the following CSS Shadow Parts: - * - group-row - Used to style the native `tr` element. - * - * @since 1.95.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export default class TableGroupRow extends WebComponent implements ITableRow { - __implements__sap_ui_webc_main_ITableRow: boolean; - /** - * Constructor for a new `TableGroupRow`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TableGroupRowSettings - ); - /** - * Constructor for a new `TableGroupRow`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TableGroupRowSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TableGroupRow with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TableGroupRow. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the TableGroupRow constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.95.0. This control is experimental and its API might change significantly. - */ - export interface $TableGroupRowSettings extends $WebComponentSettings { - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/TableRow" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { - ITableRow, - ITableCell, - TableRowType, - } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.TableRow` component represents a row in the `sap.ui.webc.main.Table`. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TableRow` exposes the following CSS Shadow Parts: - * - row - Used to style the native `tr` element - * - popin-row - Used to style the `tr` element when a row pops in - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TableRow extends WebComponent implements ITableRow { - __implements__sap_ui_webc_main_ITableRow: boolean; - /** - * Constructor for a new `TableRow`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TableRowSettings - ); - /** - * Constructor for a new `TableRow`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TableRowSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TableRow with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TableRow. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some cell to the aggregation {@link #getCells cells}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addCell( - /** - * The cell to add; if empty, nothing is inserted - */ - oCell: ITableCell - ): this; - /** - * Destroys all the cells in the aggregation {@link #getCells cells}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyCells(): this; - /** - * Gets content of aggregation {@link #getCells cells}. - * - * Defines the cells of the component. - * - * **Note:** Use `sap.ui.webc.main.TableCell` for the intended design. - */ - getCells(): ITableCell[]; - /** - * Gets current value of property {@link #getNavigated navigated}. - * - * Indicates if the table row is navigated. - * - * Default value is `false`. - * - * - * @returns Value of property `navigated` - */ - getNavigated(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the row's selected state. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the visual indication and behavior of the component. - * - * Available options are: - * - `Active` - * - `Inactive` - * - * **Note:** When set to `Active`, the item will provide visual response upon press, while with type `Inactive` - * - will not. - * - * Default value is `Inactive`. - * - * - * @returns Value of property `type` - */ - getType(): TableRowType; - /** - * Checks for the provided `sap.ui.webc.main.ITableCell` in the aggregation {@link #getCells cells}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfCell( - /** - * The cell whose index is looked for - */ - oCell: ITableCell - ): int; - /** - * Inserts a cell into the aggregation {@link #getCells cells}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertCell( - /** - * The cell to insert; if empty, nothing is inserted - */ - oCell: ITableCell, - /** - * The `0`-based index the cell should be inserted at; for a negative value of `iIndex`, the cell is inserted - * at position 0; for a value greater than the current size of the aggregation, the cell is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getCells cells}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllCells(): ITableCell[]; - /** - * Removes a cell from the aggregation {@link #getCells cells}. - * - * - * @returns The removed cell or `null` - */ - removeCell( - /** - * The cell to remove or its index or id - */ - vCell: int | string | ITableCell - ): ITableCell | null; - /** - * Sets a new value for property {@link #getNavigated navigated}. - * - * Indicates if the table row is navigated. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNavigated( - /** - * New value for property `navigated` - */ - bNavigated?: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the row's selected state. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the visual indication and behavior of the component. - * - * Available options are: - * - `Active` - * - `Inactive` - * - * **Note:** When set to `Active`, the item will provide visual response upon press, while with type `Inactive` - * - will not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Inactive`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: TableRowType | keyof typeof TableRowType - ): this; - } - /** - * Describes the settings that can be provided to the TableRow constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TableRowSettings extends $WebComponentSettings { - /** - * Indicates if the table row is navigated. - */ - navigated?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the row's selected state. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visual indication and behavior of the component. - * - * Available options are: - * - `Active` - * - `Inactive` - * - * **Note:** When set to `Active`, the item will provide visual response upon press, while with type `Inactive` - * - will not. - */ - type?: - | (TableRowType | keyof typeof TableRowType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the cells of the component. - * - * **Note:** Use `sap.ui.webc.main.TableCell` for the intended design. - */ - cells?: ITableCell[] | ITableCell | AggregationBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/TabSeparator" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITab } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - /** - * The `sap.ui.webc.main.TabSeparator` represents a vertical line to separate tabs inside a `sap.ui.webc.main.TabContainer`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TabSeparator extends WebComponent implements ITab { - __implements__sap_ui_webc_main_ITab: boolean; - /** - * Constructor for a new `TabSeparator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - * - * This class does not have its own settings, but all settings applicable to the base type {@link sap.ui.core.webc.WebComponent#constructor sap.ui.core.webc.WebComponent } - * can be used. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TabSeparatorSettings - ); - /** - * Constructor for a new `TabSeparator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - * - * This class does not have its own settings, but all settings applicable to the base type {@link sap.ui.core.webc.WebComponent#constructor sap.ui.core.webc.WebComponent } - * can be used. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TabSeparatorSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TabSeparator with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TabSeparator. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Returns the DOM reference of the separator that is placed in the header. **Note:** Tabs and separators, - * placed in the `subTabs` slot of other tabs are not shown in the header. Calling this method on such tabs - * or separators will return `null`. - */ - getTabInStripDomRef(): void; - } - /** - * Describes the settings that can be provided to the TabSeparator constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TabSeparatorSettings extends $WebComponentSettings {} -} - -declare module "sap/ui/webc/main/TextArea" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ID, CSSSize, ValueState } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.TextArea` component is used to enter multiple lines of text. - * - * When empty, it can hold a placeholder similar to a `sap.ui.webc.main.Input`. You can define the rows - * of the `sap.ui.webc.main.TextArea` and also determine specific behavior when handling long texts. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TextArea` exposes the following CSS Shadow Parts: - * - textarea - Used to style the native textarea - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TextArea extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `TextArea`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TextAreaSettings - ); - /** - * Constructor for a new `TextArea`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TextAreaSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TextArea with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TextArea. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.TextArea`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TextArea` itself. - * - * Fired when the text has changed and the focus leaves the component. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TextArea` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.TextArea`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TextArea` itself. - * - * Fired when the text has changed and the focus leaves the component. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TextArea` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.TextArea`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TextArea` itself. - * - * Fired when the value of the component changes at each keystroke or when something is pasted. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TextArea` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.TextArea`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TextArea` itself. - * - * Fired when the value of the component changes at each keystroke or when something is pasted. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TextArea` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.TextArea`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.TextArea`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getGrowing growing}. - * - * Enables the component to automatically grow and shrink dynamically with its content. - * - * - * - * Default value is `false`. - * - * - * @returns Value of property `growing` - */ - getGrowing(): boolean; - /** - * Gets current value of property {@link #getGrowingMaxLines growingMaxLines}. - * - * Defines the maximum number of lines that the component can grow. - * - * Default value is `0`. - * - * - * @returns Value of property `growingMaxLines` - */ - getGrowingMaxLines(): int; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getMaxlength maxlength}. - * - * Defines the maximum number of characters that the `value` can have. - * - * - * @returns Value of property `maxlength` - */ - getMaxlength(): int; - /** - * Gets current value of property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * Default value is `empty string`. - * - * - * @returns Value of property `name` - */ - getName(): string; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * Default value is `empty string`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * Default value is `false`. - * - * - * @returns Value of property `required` - */ - getRequired(): boolean; - /** - * Gets current value of property {@link #getRows rows}. - * - * Defines the number of visible text lines for the component. - * - * **Notes:** - * - If the `growing` property is enabled, this property defines the minimum rows to be displayed in the - * textarea. - * - The CSS `height` property wins over the `rows` property, if both are set. - * - * Default value is `0`. - * - * - * @returns Value of property `rows` - */ - getRows(): int; - /** - * Gets current value of property {@link #getShowExceededText showExceededText}. - * - * Determines whether the characters exceeding the maximum allowed character count are visible in the component. - * - * - * If set to `false`, the user is not allowed to enter more characters than what is set in the `maxlength` - * property. If set to `true` the characters exceeding the `maxlength` value are selected on paste and the - * counter below the component displays their number. - * - * Default value is `false`. - * - * - * @returns Value of property `showExceededText` - */ - getShowExceededText(): boolean; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines the value of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * - * - * **Note:** If `maxlength` property is set, the component turns into "Warning" state once the characters - * exceeds the limit. In this case, only the "Error" state is considered and can be applied. - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getGrowing growing}. - * - * Enables the component to automatically grow and shrink dynamically with its content. - * - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setGrowing( - /** - * New value for property `growing` - */ - bGrowing?: boolean - ): this; - /** - * Sets a new value for property {@link #getGrowingMaxLines growingMaxLines}. - * - * Defines the maximum number of lines that the component can grow. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setGrowingMaxLines( - /** - * New value for property `growingMaxLines` - */ - iGrowingMaxLines?: int - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getMaxlength maxlength}. - * - * Defines the maximum number of characters that the `value` can have. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMaxlength( - /** - * New value for property `maxlength` - */ - iMaxlength?: int - ): this; - /** - * Sets a new value for property {@link #getName name}. - * - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setName( - /** - * New value for property `name` - */ - sName?: string - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint intended to aid the user with data entry when the component has no value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getRequired required}. - * - * Defines whether the component is required. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRequired( - /** - * New value for property `required` - */ - bRequired?: boolean - ): this; - /** - * Sets a new value for property {@link #getRows rows}. - * - * Defines the number of visible text lines for the component. - * - * **Notes:** - * - If the `growing` property is enabled, this property defines the minimum rows to be displayed in the - * textarea. - * - The CSS `height` property wins over the `rows` property, if both are set. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `0`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setRows( - /** - * New value for property `rows` - */ - iRows?: int - ): this; - /** - * Sets a new value for property {@link #getShowExceededText showExceededText}. - * - * Determines whether the characters exceeding the maximum allowed character count are visible in the component. - * - * - * If set to `false`, the user is not allowed to enter more characters than what is set in the `maxlength` - * property. If set to `true` the characters exceeding the `maxlength` value are selected on paste and the - * counter below the component displays their number. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setShowExceededText( - /** - * New value for property `showExceededText` - */ - bShowExceededText?: boolean - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines the value of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * - * - * **Note:** If `maxlength` property is set, the component turns into "Warning" state once the characters - * exceeds the limit. In this case, only the "Error" state is considered and can be applied. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the TextArea constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TextAreaSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Enables the component to automatically grow and shrink dynamically with its content. - */ - growing?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the maximum number of lines that the component can grow. - */ - growingMaxLines?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the maximum number of characters that the `value` can have. - */ - maxlength?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the name with which the component will be submitted in an HTML form. - * - * - * - * **Note:** When set, a native `input` HTML element will be created inside the component so that it can - * be submitted as part of an HTML form. Do not use this property unless you need to submit a form. - */ - name?: string | PropertyBindingInfo; - - /** - * Defines a short hint intended to aid the user with data entry when the component has no value. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component is not editable, but still provides visual feedback upon user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is required. - */ - required?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the number of visible text lines for the component. - * - * **Notes:** - * - If the `growing` property is enabled, this property defines the minimum rows to be displayed in the - * textarea. - * - The CSS `height` property wins over the `rows` property, if both are set. - */ - rows?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Determines whether the characters exceeding the maximum allowed character count are visible in the component. - * - * - * If set to `false`, the user is not allowed to enter more characters than what is set in the `maxlength` - * property. If set to `true` the characters exceeding the `maxlength` value are selected on paste and the - * counter below the component displays their number. - */ - showExceededText?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the value of the component. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the component. - * - * - * - * **Note:** If `maxlength` property is set, the component turns into "Warning" state once the characters - * exceeds the limit. In this case, only the "Error" state is considered and can be applied. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the text has changed and the focus leaves the component. - */ - change?: (oEvent: Event) => void; - - /** - * Fired when the value of the component changes at each keystroke or when something is pasted. - */ - input?: (oEvent: Event) => void; - } - - /** - * Parameters of the TextArea#change event. - */ - export interface TextArea$ChangeEventParameters {} - - /** - * Event object of the TextArea#change event. - */ - export type TextArea$ChangeEvent = Event< - TextArea$ChangeEventParameters, - TextArea - >; - - /** - * Parameters of the TextArea#input event. - */ - export interface TextArea$InputEventParameters {} - - /** - * Event object of the TextArea#input event. - */ - export type TextArea$InputEvent = Event< - TextArea$InputEventParameters, - TextArea - >; -} - -declare module "sap/ui/webc/main/TimePicker" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IFormContent, ValueState, CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The `sap.ui.webc.main.TimePicker` component provides an input field with assigned clocks which - * are opened on user action. The `sap.ui.webc.main.TimePicker` allows users to select a localized time - * using touch, mouse, or keyboard input. It consists of two parts: the time input field and the clocks. - * - * Usage: The user can enter a time by: - * - Using the clocks that are displayed in a popup - * - Typing it in directly in the input field - * - * When the user makes an entry and chooses the enter key, the clocks show the corresponding time (hours, - * minutes and seconds separately). When the user directly triggers the clocks display, the actual time - * is displayed. For the `sap.ui.webc.main.TimePicker` - * - * Formatting: - * - * If a time is entered by typing it into the input field, it must fit to the used time format. - * - * Supported format options are pattern-based on Unicode LDML Date Format notation. For more information, - * see {@link http://unicode.org/reports/tr35/#Date_Field_Symbol_Table UTS #35: Unicode Locale Data Markup Language}. - * - * - * For example, if the `format-pattern` is "HH:mm:ss", a valid value string is "11:42:35" and the same - * is displayed in the input. - * - * Keyboard handling: [F4], [ALT]+[UP], [ALT]+[DOWN] Open/Close picker dialog and move focus to it. - * When closed: - * - [PAGEUP] - Increments hours by 1. If 12 am is reached, increment hours to 1 pm and vice versa. - * - [PAGEDOWN] - Decrements the corresponding field by 1. If 1 pm is reached, decrement hours to 12 am - * and vice versa. - * - [SHIFT]+[PAGEUP] - Increments minutes by 1. - * - [SHIFT]+[PAGEDOWN] - Decrements minutes by 1. - * - [SHIFT]+[CTRL]+[PAGEUP] - Increments seconds by 1. - * - [SHIFT]+[CTRL]+[PAGEDOWN] - Decrements seconds by 1. - * - When opened: - * [PAGEUP] - Increments hours by 1. If 12 am is reached, increment hours to 1 pm and vice versa. - * - [PAGEDOWN] - Decrements the corresponding field by 1. If 1 pm is reached, decrement hours to 12 am - * and vice versa. - * - [SHIFT]+[PAGEUP] - Increments minutes by 1. - * - [SHIFT]+[PAGEDOWN] - Decrements minutes by 1. - * - [SHIFT]+[CTRL]+[PAGEUP] - Increments seconds by 1. - * - [SHIFT]+[CTRL]+[PAGEDOWN] - Decrements seconds by 1. - * - [A] or [P] - Selects AM or PM respectively. - * - [0]-[9] - Allows direct time selecting (hours/minutes/seconds). - * - [:] - Allows switching between hours/minutes/seconds clocks. If the last clock is displayed and [:] - * is pressed, the first clock is beind displayed. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TimePicker extends WebComponent implements IFormContent { - __implements__sap_ui_core_IFormContent: boolean; - /** - * Constructor for a new `TimePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TimePickerSettings - ); - /** - * Constructor for a new `TimePicker`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TimePickerSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TimePicker with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TimePicker. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.TimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TimePicker` itself. - * - * Fired when the input operation has finished by clicking the "OK" button or when the text in the input - * field has changed and the focus leaves the input field. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: TimePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TimePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.TimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TimePicker` itself. - * - * Fired when the input operation has finished by clicking the "OK" button or when the text in the input - * field has changed and the focus leaves the input field. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: TimePicker$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TimePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.TimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TimePicker` itself. - * - * Fired when the value of the `sap.ui.webc.main.TimePicker` is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: TimePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TimePicker` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:input input} event of this `sap.ui.webc.main.TimePicker`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TimePicker` itself. - * - * Fired when the value of the `sap.ui.webc.main.TimePicker` is changed at each key stroke. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachInput( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: TimePicker$InputEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TimePicker` itself - */ - oListener?: object - ): this; - /** - * Closes the picker - */ - closePicker(): void; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.TimePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: TimePicker$ChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:input input} event of this `sap.ui.webc.main.TimePicker`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachInput( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: TimePicker$InputEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: TimePicker$ChangeEventParameters - ): this; - /** - * Fires event {@link #event:input input} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireInput( - /** - * Parameters to pass along with the event - */ - mParameters?: TimePicker$InputEventParameters - ): this; - /** - * Formats a Java Script date object into a string representing a locale date and time according to the - * `formatPattern` property of the TimePicker instance - */ - formatValue( - /** - * A Java Script date object to be formatted as string - */ - date: Date - ): void; - /** - * Returns the currently selected time represented as JavaScript Date instance - */ - getDateValue(): void; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * Example: HH:mm:ss -> 11:42:35 hh:mm:ss a -> 2:23:15 PM mm:ss -> 12:04 (only minutes and seconds) - * - * Default value is `empty string`. - * - * - * @returns Value of property `formatPattern` - */ - getFormatPattern(): string; - /** - * Gets current value of property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * Default value is `undefined`. - * - * - * @returns Value of property `placeholder` - */ - getPlaceholder(): string; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Determines whether the `sap.ui.webc.main.TimePicker` is displayed as readonly. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getValue value}. - * - * Defines a formatted time value. - * - * Default value is `undefined`. - * - * - * @returns Value of property `value` - */ - getValue(): string; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the `sap.ui.webc.main.TimePicker`. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * Default value is `empty string`. - * - * - * @returns Value of property `valueStateMessage` - */ - getValueStateMessage(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks if the picker is open - */ - isOpen(): void; - /** - * Checks if a value is valid against the current `formatPattern` value. - * - * - * - * **Note:** an empty string is considered as valid value. - */ - isValid( - /** - * The value to be tested against the current date format - */ - value: string - ): void; - /** - * Opens the picker. - */ - openPicker(): void; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getFormatPattern formatPattern}. - * - * Determines the format, displayed in the input field. - * - * Example: HH:mm:ss -> 11:42:35 hh:mm:ss a -> 2:23:15 PM mm:ss -> 12:04 (only minutes and seconds) - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFormatPattern( - /** - * New value for property `formatPattern` - */ - sFormatPattern?: string - ): this; - /** - * Sets a new value for property {@link #getPlaceholder placeholder}. - * - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlaceholder( - /** - * New value for property `placeholder` - */ - sPlaceholder?: string - ): this; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Determines whether the `sap.ui.webc.main.TimePicker` is displayed as readonly. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getValue value}. - * - * Defines a formatted time value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValue( - /** - * New value for property `value` - */ - sValue?: string - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the `sap.ui.webc.main.TimePicker`. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getValueStateMessage valueStateMessage}. - * - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueStateMessage( - /** - * New value for property `valueStateMessage` - */ - sValueStateMessage?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the TimePicker constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TimePickerSettings extends $WebComponentSettings { - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines the format, displayed in the input field. - * - * Example: HH:mm:ss -> 11:42:35 hh:mm:ss a -> 2:23:15 PM mm:ss -> 12:04 (only minutes and seconds) - */ - formatPattern?: string | PropertyBindingInfo; - - /** - * Defines a short hint, intended to aid the user with data entry when the component has no value. - * - * - * - * **Note:** When no placeholder is set, the format pattern is displayed as a placeholder. Passing an empty - * string as the value of this property will make the component appear empty - without placeholder or format - * pattern. - */ - placeholder?: string | PropertyBindingInfo; - - /** - * Determines whether the `sap.ui.webc.main.TimePicker` is displayed as readonly. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines a formatted time value. - */ - value?: string | PropertyBindingInfo; - - /** - * Defines the value state of the `sap.ui.webc.main.TimePicker`. - * - * Available options are: - * - `None` - * - `Error` - * - `Warning` - * - `Success` - * - `Information` - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the value state message that will be displayed as pop up under the contorl. - * - * - * - * **Note:** If not specified, a default text (in the respective language) will be displayed. - */ - valueStateMessage?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Fired when the input operation has finished by clicking the "OK" button or when the text in the input - * field has changed and the focus leaves the input field. - */ - change?: (oEvent: TimePicker$ChangeEvent) => void; - - /** - * Fired when the value of the `sap.ui.webc.main.TimePicker` is changed at each key stroke. - */ - input?: (oEvent: TimePicker$InputEvent) => void; - } - - /** - * Parameters of the TimePicker#change event. - */ - export interface TimePicker$ChangeEventParameters { - /** - * The submitted value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the TimePicker#change event. - */ - export type TimePicker$ChangeEvent = Event< - TimePicker$ChangeEventParameters, - TimePicker - >; - - /** - * Parameters of the TimePicker#input event. - */ - export interface TimePicker$InputEventParameters { - /** - * The current value. - */ - value?: string; - - /** - * Indicator if the value is in correct format pattern and in valid range. - */ - valid?: boolean; - } - - /** - * Event object of the TimePicker#input event. - */ - export type TimePicker$InputEvent = Event< - TimePicker$InputEventParameters, - TimePicker - >; -} - -declare module "sap/ui/webc/main/Title" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { TitleLevel, WrappingType } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { CSSSize } from "sap/ui/core/library"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Title` component is used to display titles inside a page. It is a simple, large-sized - * text with explicit header/title semantics. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Title extends WebComponent { - /** - * Constructor for a new `Title`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TitleSettings - ); - /** - * Constructor for a new `Title`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TitleSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Title with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Title. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getLevel level}. - * - * Defines the component level. Available options are: `"H6"` to `"H1"`. - * - * Default value is `H2`. - * - * - * @returns Value of property `level` - */ - getLevel(): TitleLevel; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Gets current value of property {@link #getWrappingType wrappingType}. - * - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * Default value is `None`. - * - * - * @returns Value of property `wrappingType` - */ - getWrappingType(): WrappingType; - /** - * Sets a new value for property {@link #getLevel level}. - * - * Defines the component level. Available options are: `"H6"` to `"H1"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `H2`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setLevel( - /** - * New value for property `level` - */ - sLevel?: TitleLevel | keyof typeof TitleLevel - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Sets a new value for property {@link #getWrappingType wrappingType}. - * - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWrappingType( - /** - * New value for property `wrappingType` - */ - sWrappingType?: WrappingType | keyof typeof WrappingType - ): this; - } - /** - * Describes the settings that can be provided to the Title constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TitleSettings extends $WebComponentSettings { - /** - * Defines the component level. Available options are: `"H6"` to `"H1"`. - */ - level?: - | (TitleLevel | keyof typeof TitleLevel) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines how the text of a component will be displayed when there is not enough space. - * **Note:** for option "Normal" the text will wrap and the words will not be broken based on hyphenation. - */ - wrappingType?: - | (WrappingType | keyof typeof WrappingType) - | PropertyBindingInfo - | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/Toast" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { CSSSize } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { ToastPlacement } from "sap/ui/webc/main/library"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Toast` is a small, non-disruptive popup for success or information messages that - * disappears automatically after a few seconds. - * - * Usage: - * - * When to use:: - * - You want to display a short success or information message. - * - You do not want to interrupt users while they are performing an action. - * - You want to confirm a successful action. When not to use:: - * - You want to display error or warning message. - * - You want to interrupt users while they are performing an action. - * - You want to make sure that users read the message before they leave the page. - * - You want users to be able to copy some part of the message text. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Toast extends WebComponent { - /** - * Constructor for a new `Toast`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToastSettings - ); - /** - * Constructor for a new `Toast`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToastSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Toast with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Toast. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getDuration duration}. - * - * Defines the duration in milliseconds for which component remains on the screen before it's automatically - * closed. - * - * **Note:** The minimum supported value is `500` ms and even if a lower value is set, the duration would - * remain `500` ms. - * - * Default value is `3000`. - * - * - * @returns Value of property `duration` - */ - getDuration(): int; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets current value of property {@link #getPlacement placement}. - * - * Defines the placement of the component. - * - * - * - * Default value is `BottomCenter`. - * - * - * @returns Value of property `placement` - */ - getPlacement(): ToastPlacement; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getDuration duration}. - * - * Defines the duration in milliseconds for which component remains on the screen before it's automatically - * closed. - * - * **Note:** The minimum supported value is `500` ms and even if a lower value is set, the duration would - * remain `500` ms. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `3000`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDuration( - /** - * New value for property `duration` - */ - iDuration?: int - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getPlacement placement}. - * - * Defines the placement of the component. - * - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `BottomCenter`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPlacement( - /** - * New value for property `placement` - */ - sPlacement?: ToastPlacement | keyof typeof ToastPlacement - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Shows the component. - */ - show(): void; - } - /** - * Describes the settings that can be provided to the Toast constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ToastSettings extends $WebComponentSettings { - /** - * Defines the duration in milliseconds for which component remains on the screen before it's automatically - * closed. - * - * **Note:** The minimum supported value is `500` ms and even if a lower value is set, the duration would - * remain `500` ms. - */ - duration?: int | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the placement of the component. - */ - placement?: - | (ToastPlacement | keyof typeof ToastPlacement) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/ToggleButton" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { ButtonDesign, ButtonType } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.ToggleButton` component is an enhanced `sap.ui.webc.main.Button` that can be toggled - * between pressed and normal states. Users can use the `sap.ui.webc.main.ToggleButton` as a switch to turn - * a setting on or off. It can also be used to represent an independent choice similar to a check box. - * - * Clicking or tapping on a `sap.ui.webc.main.ToggleButton` changes its state to `pressed`. The button - * returns to its initial state when the user clicks or taps on it again. By applying additional custom - * CSS-styling classes, apps can give a different style to any `sap.ui.webc.main.ToggleButton`. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class ToggleButton extends WebComponent { - /** - * Constructor for a new `ToggleButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToggleButtonSettings - ); - /** - * Constructor for a new `ToggleButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToggleButtonSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ToggleButton with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ToggleButton. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.ToggleButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToggleButton` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToggleButton` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.ToggleButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToggleButton` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToggleButton` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.ToggleButton`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the component design. - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): ButtonDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIconEnd iconEnd}. - * - * Defines whether the icon should be displayed after the component text. - * - * Default value is `false`. - * - * - * @returns Value of property `iconEnd` - */ - getIconEnd(): boolean; - /** - * Gets current value of property {@link #getPressed pressed}. - * - * Determines whether the component is displayed as pressed. - * - * Default value is `false`. - * - * - * @returns Value of property `pressed` - */ - getPressed(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getType type}. - * - * Defines whether the button has special form-related functionality. - * - * Default value is `Button`. - * - * - * @returns Value of property `type` - */ - getType(): ButtonType; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the component design. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: ButtonDesign | keyof typeof ButtonDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getIconEnd iconEnd}. - * - * Defines whether the icon should be displayed after the component text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIconEnd( - /** - * New value for property `iconEnd` - */ - bIconEnd?: boolean - ): this; - /** - * Sets a new value for property {@link #getPressed pressed}. - * - * Determines whether the component is displayed as pressed. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setPressed( - /** - * New value for property `pressed` - */ - bPressed?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines whether the button has special form-related functionality. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Button`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ButtonType | keyof typeof ButtonType - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the ToggleButton constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $ToggleButtonSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the component design. - */ - design?: - | (ButtonDesign | keyof typeof ButtonDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the icon, displayed as graphical element within the component. The SAP-icons font provides numerous - * options. - * - * Example: - * - * See all the available icons within the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the icon should be displayed after the component text. - */ - iconEnd?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Determines whether the component is displayed as pressed. - */ - pressed?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - - /** - * Defines whether the button has special form-related functionality. - */ - type?: - | (ButtonType | keyof typeof ButtonType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the ToggleButton#click event. - */ - export interface ToggleButton$ClickEventParameters {} - - /** - * Event object of the ToggleButton#click event. - */ - export type ToggleButton$ClickEvent = Event< - ToggleButton$ClickEventParameters, - ToggleButton - >; -} - -declare module "sap/ui/webc/main/Token" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IToken, IIcon } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * Tokens are small items of information (similar to tags) that mainly serve to visualize previously selected - * items. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Token extends WebComponent implements IToken { - __implements__sap_ui_webc_main_IToken: boolean; - /** - * Constructor for a new `Token`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TokenSettings - ); - /** - * Constructor for a new `Token`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TokenSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Token with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Token. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some closeIcon to the aggregation {@link #getCloseIcon closeIcon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addCloseIcon( - /** - * The closeIcon to add; if empty, nothing is inserted - */ - oCloseIcon: IIcon - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:select select} event of this `sap.ui.webc.main.Token`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Token` itself. - * - * Fired when the the component is selected by user interaction with mouse or by clicking space. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelect( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Token` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:select select} event of this `sap.ui.webc.main.Token`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Token` itself. - * - * Fired when the the component is selected by user interaction with mouse or by clicking space. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelect( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Token` itself - */ - oListener?: object - ): this; - /** - * Destroys all the closeIcon in the aggregation {@link #getCloseIcon closeIcon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyCloseIcon(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:select select} event of this `sap.ui.webc.main.Token`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelect( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:select select} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelect( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets content of aggregation {@link #getCloseIcon closeIcon}. - * - * Defines the close icon for the token. If nothing is provided to this slot, the default close icon will - * be used. Accepts `sap.ui.webc.main.Icon`. - */ - getCloseIcon(): IIcon[]; - /** - * Gets current value of property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component can not be deleted or selected, but still provides visual feedback upon - * user interaction. - * - * Default value is `false`. - * - * - * @returns Value of property `readonly` - */ - getReadonly(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines whether the component is selected or not. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the token. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Checks for the provided `sap.ui.webc.main.IIcon` in the aggregation {@link #getCloseIcon closeIcon}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfCloseIcon( - /** - * The closeIcon whose index is looked for - */ - oCloseIcon: IIcon - ): int; - /** - * Inserts a closeIcon into the aggregation {@link #getCloseIcon closeIcon}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertCloseIcon( - /** - * The closeIcon to insert; if empty, nothing is inserted - */ - oCloseIcon: IIcon, - /** - * The `0`-based index the closeIcon should be inserted at; for a negative value of `iIndex`, the closeIcon - * is inserted at position 0; for a value greater than the current size of the aggregation, the closeIcon - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getCloseIcon closeIcon}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllCloseIcon(): IIcon[]; - /** - * Removes a closeIcon from the aggregation {@link #getCloseIcon closeIcon}. - * - * - * @returns The removed closeIcon or `null` - */ - removeCloseIcon( - /** - * The closeIcon to remove or its index or id - */ - vCloseIcon: int | string | IIcon - ): IIcon | null; - /** - * Sets a new value for property {@link #getReadonly readonly}. - * - * Defines whether the component is read-only. - * - * **Note:** A read-only component can not be deleted or selected, but still provides visual feedback upon - * user interaction. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setReadonly( - /** - * New value for property `readonly` - */ - bReadonly?: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines whether the component is selected or not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the token. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the Token constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TokenSettings extends $WebComponentSettings { - /** - * Defines whether the component is read-only. - * - * **Note:** A read-only component can not be deleted or selected, but still provides visual feedback upon - * user interaction. - */ - readonly?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the component is selected or not. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the token. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the close icon for the token. If nothing is provided to this slot, the default close icon will - * be used. Accepts `sap.ui.webc.main.Icon`. - */ - closeIcon?: IIcon[] | IIcon | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the the component is selected by user interaction with mouse or by clicking space. - */ - select?: (oEvent: Event) => void; - } - - /** - * Parameters of the Token#select event. - */ - export interface Token$SelectEventParameters {} - - /** - * Event object of the Token#select event. - */ - export type Token$SelectEvent = Event; -} - -declare module "sap/ui/webc/main/Toolbar" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { IToolbarItem, ToolbarAlign } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.Toolbar` component is used to create a horizontal layout with items. The items - * can be overflowing in a popover, when the space is not enough to show all of them. - * - * Keyboard Handling: The `sap.ui.webc.main.Toolbar` provides advanced keyboard handling. - * - * - * - * - The control is not interactive, but can contain of interactive elements - * - [TAB] - iterates through elements - * - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class Toolbar extends WebComponent { - /** - * Constructor for a new `Toolbar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSettings - ); - /** - * Constructor for a new `Toolbar`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Toolbar with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Toolbar. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: IToolbarItem - ): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAlignContent alignContent}. - * - * Indicated the direction in which the Toolbar items will be aligned. Available options are: - * - `End` - * - `Start` - * - * - * @returns Value of property `alignContent` - */ - getAlignContent(): ToolbarAlign; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the component. - * - * **Note:** Currently only `sap.ui.webc.main.ToolbarButton`, `sap.ui.webc.main.ToolbarSelect`, `sap.ui.webc.main.ToolbarSeparator` - * and `sap.ui.webc.main.ToolbarSpacer` are allowed here. - */ - getItems(): IToolbarItem[]; - /** - * Checks for the provided `sap.ui.webc.main.IToolbarItem` in the aggregation {@link #getItems items}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: IToolbarItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: IToolbarItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): IToolbarItem[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | IToolbarItem - ): IToolbarItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getAlignContent alignContent}. - * - * Indicated the direction in which the Toolbar items will be aligned. Available options are: - * - `End` - * - `Start` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAlignContent( - /** - * New value for property `alignContent` - */ - sAlignContent: ToolbarAlign | keyof typeof ToolbarAlign - ): this; - } - /** - * Describes the settings that can be provided to the Toolbar constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $ToolbarSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Indicated the direction in which the Toolbar items will be aligned. Available options are: - * - `End` - * - `Start` - */ - alignContent?: - | (ToolbarAlign | keyof typeof ToolbarAlign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the items of the component. - * - * **Note:** Currently only `sap.ui.webc.main.ToolbarButton`, `sap.ui.webc.main.ToolbarSelect`, `sap.ui.webc.main.ToolbarSeparator` - * and `sap.ui.webc.main.ToolbarSpacer` are allowed here. - */ - items?: - | IToolbarItem[] - | IToolbarItem - | AggregationBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - } -} - -declare module "sap/ui/webc/main/ToolbarButton" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IToolbarItem, ButtonDesign } from "sap/ui/webc/main/library"; - - import { ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.ToolbarButton` represents an abstract action, used in the `sap.ui.webc.main.Toolbar`. - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class ToolbarButton - extends WebComponent - implements IToolbarItem - { - __implements__sap_ui_webc_main_IToolbarItem: boolean; - /** - * Constructor for a new `ToolbarButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarButtonSettings - ); - /** - * Constructor for a new `ToolbarButton`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarButtonSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ToolbarButton with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ToolbarButton. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.ToolbarButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarButton` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarButton` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:click click} event of this `sap.ui.webc.main.ToolbarButton`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarButton` itself. - * - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarButton` itself - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:click click} event of this `sap.ui.webc.main.ToolbarButton`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:click click} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `undefined`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getDesign design}. - * - * Defines the action design. **The available values are:** - * - * - * - `Default` - * - `Emphasized` - * - `Positive` - * - `Negative` - * - `Transparent` - * - `Attention` - * - * Default value is `Default`. - * - * - * @returns Value of property `design` - */ - getDesign(): ButtonDesign; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous buil-in icons. To find all the available icons, see the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIconEnd iconEnd}. - * - * Defines whether the icon should be displayed after the component text. - * - * Default value is `false`. - * - * - * @returns Value of property `iconEnd` - */ - getIconEnd(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Button text - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the button. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - * - * Default value is `undefined`. - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getDesign design}. - * - * Defines the action design. **The available values are:** - * - * - * - `Default` - * - `Emphasized` - * - `Positive` - * - `Negative` - * - `Transparent` - * - `Attention` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Default`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDesign( - /** - * New value for property `design` - */ - sDesign?: ButtonDesign | keyof typeof ButtonDesign - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous buil-in icons. To find all the available icons, see the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getIconEnd iconEnd}. - * - * Defines whether the icon should be displayed after the component text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIconEnd( - /** - * New value for property `iconEnd` - */ - bIconEnd?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Button text - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the button. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth?: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the ToolbarButton constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $ToolbarButtonSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `expanded`: Indicates whether the button, or another grouping element it controls, is currently expanded - * or collapsed. Accepts the following string values: - * `true` - * - `false` - * - `hasPopup`: Indicates the availability and type of interactive popup element, such as menu or dialog, - * that can be triggered by the button. Accepts the following string values: - * `Dialog` - * - `Grid` - * - `ListBox` - * - `Menu` - * - `Tree` - * - `controls`: Identifies the element (or elements) whose contents or presence are controlled by the - * button element. Accepts a string value. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the action design. **The available values are:** - * - * - * - `Default` - * - `Emphasized` - * - `Positive` - * - `Negative` - * - `Transparent` - * - `Attention` - */ - design?: - | (ButtonDesign | keyof typeof ButtonDesign) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the `icon` source URI. - * - * **Note:** SAP-icons font provides numerous buil-in icons. To find all the available icons, see the {@link demo:sap/m/demokit/iconExplorer/webapp/index.html Icon Explorer}. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the icon should be displayed after the component text. - */ - iconEnd?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Button text - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the width of the button. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the component is activated either with a mouse/tap or by using the Enter or Space key. - * - * **Note:** The event will not be fired if the `disabled` property is set to `true`. - */ - click?: (oEvent: Event) => void; - } - - /** - * Parameters of the ToolbarButton#click event. - */ - export interface ToolbarButton$ClickEventParameters {} - - /** - * Event object of the ToolbarButton#click event. - */ - export type ToolbarButton$ClickEvent = Event< - ToolbarButton$ClickEventParameters, - ToolbarButton - >; -} - -declare module "sap/ui/webc/main/ToolbarSelect" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IToolbarItem, ISelectOption } from "sap/ui/webc/main/library"; - - import { ID, ValueState, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.ToolbarSelect` component is used to create a toolbar drop-down list. - * The items inside the `sap.ui.webc.main.ToolbarSelect` define the available options by using the `sap.ui.webc.main.ToolbarSelectOption` - * component. - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class ToolbarSelect - extends WebComponent - implements IToolbarItem - { - __implements__sap_ui_webc_main_IToolbarItem: boolean; - /** - * Constructor for a new `ToolbarSelect`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSelectSettings - ); - /** - * Constructor for a new `ToolbarSelect`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSelectSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ToolbarSelect with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ToolbarSelect. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some option to the aggregation {@link #getOptions options}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addOption( - /** - * The option to add; if empty, nothing is inserted - */ - oOption: ISelectOption - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarSelect` itself. - * - * Fired when the selected option changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ToolbarSelect$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarSelect` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:change change} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarSelect` itself. - * - * Fired when the selected option changes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: ToolbarSelect$ChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarSelect` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarSelect` itself. - * - * Fired after the component's dropdown menu closes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarSelect` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:close close} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarSelect` itself. - * - * Fired after the component's dropdown menu closes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachClose( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarSelect` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:open open} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarSelect` itself. - * - * Fired after the component's dropdown menu opens. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOpen( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarSelect` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:open open} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.ToolbarSelect` itself. - * - * Fired after the component's dropdown menu opens. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachOpen( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.ToolbarSelect` itself - */ - oListener?: object - ): this; - /** - * Destroys all the options in the aggregation {@link #getOptions options}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyOptions(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:change change} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: ToolbarSelect$ChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:close close} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachClose( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:open open} event of this `sap.ui.webc.main.ToolbarSelect`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachOpen( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:change change} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireChange( - /** - * Parameters to pass along with the event - */ - mParameters?: ToolbarSelect$ChangeEventParameters - ): boolean; - /** - * Fires event {@link #event:close close} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireClose( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Fires event {@link #event:open open} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireOpen( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * Default value is `empty string`. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * Default value is `true`. - * - * - * @returns Value of property `enabled` - */ - getEnabled(): boolean; - /** - * Gets content of aggregation {@link #getOptions options}. - * - * Defines the component options. - * - * - * - * **Note:** Only one selected option is allowed. If more than one option is defined as selected, the last - * one would be considered as the selected one. - * - * - * - * **Note:** Use the `sap.ui.webc.main.ToolbarSelectOption` component to define the desired options. - */ - getOptions(): ISelectOption[]; - /** - * Gets current value of property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * - * - * Default value is `None`. - * - * - * @returns Value of property `valueState` - */ - getValueState(): ValueState; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the select. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - * - * Default value is `undefined`. - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.webc.main.ISelectOption` in the aggregation {@link #getOptions options}. - * and returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfOption( - /** - * The option whose index is looked for - */ - oOption: ISelectOption - ): int; - /** - * Inserts a option into the aggregation {@link #getOptions options}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertOption( - /** - * The option to insert; if empty, nothing is inserted - */ - oOption: ISelectOption, - /** - * The `0`-based index the option should be inserted at; for a negative value of `iIndex`, the option is - * inserted at position 0; for a value greater than the current size of the aggregation, the option is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getOptions options}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllOptions(): ISelectOption[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a option from the aggregation {@link #getOptions options}. - * - * - * @returns The removed option or `null` - */ - removeOption( - /** - * The option to remove or its index or id - */ - vOption: int | string | ISelectOption - ): ISelectOption | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible ARIA name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName?: string - ): this; - /** - * Sets a new value for property {@link #getEnabled enabled}. - * - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `true`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setEnabled( - /** - * New value for property `enabled` - */ - bEnabled?: boolean - ): this; - /** - * Sets a new value for property {@link #getValueState valueState}. - * - * Defines the value state of the component. - * - * - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setValueState( - /** - * New value for property `valueState` - */ - sValueState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the select. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth?: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the ToolbarSelect constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $ToolbarSelectSettings extends $WebComponentSettings { - /** - * Defines the accessible ARIA name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines whether the control is enabled. A disabled control can't be interacted with, and it is not in - * the tab chain. - */ - enabled?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the value state of the component. - */ - valueState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the width of the select. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the component options. - * - * - * - * **Note:** Only one selected option is allowed. If more than one option is defined as selected, the last - * one would be considered as the selected one. - * - * - * - * **Note:** Use the `sap.ui.webc.main.ToolbarSelectOption` component to define the desired options. - */ - options?: - | ISelectOption[] - | ISelectOption - | AggregationBindingInfo - | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when the selected option changes. - */ - change?: (oEvent: ToolbarSelect$ChangeEvent) => void; - - /** - * Fired after the component's dropdown menu closes. - */ - close?: (oEvent: Event) => void; - - /** - * Fired after the component's dropdown menu opens. - */ - open?: (oEvent: Event) => void; - } - - /** - * Parameters of the ToolbarSelect#change event. - */ - export interface ToolbarSelect$ChangeEventParameters { - /** - * the selected option. - */ - selectedOption?: HTMLElement; - } - - /** - * Event object of the ToolbarSelect#change event. - */ - export type ToolbarSelect$ChangeEvent = Event< - ToolbarSelect$ChangeEventParameters, - ToolbarSelect - >; - - /** - * Parameters of the ToolbarSelect#close event. - */ - export interface ToolbarSelect$CloseEventParameters {} - - /** - * Event object of the ToolbarSelect#close event. - */ - export type ToolbarSelect$CloseEvent = Event< - ToolbarSelect$CloseEventParameters, - ToolbarSelect - >; - - /** - * Parameters of the ToolbarSelect#open event. - */ - export interface ToolbarSelect$OpenEventParameters {} - - /** - * Event object of the ToolbarSelect#open event. - */ - export type ToolbarSelect$OpenEvent = Event< - ToolbarSelect$OpenEventParameters, - ToolbarSelect - >; -} - -declare module "sap/ui/webc/main/ToolbarSelectOption" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IToolbarSelectOption } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: - * - * The `sap.ui.webc.main.ToolbarSelectOption` component defines the content of an option in the `sap.ui.webc.main.ToolbarSelect`. - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class ToolbarSelectOption - extends WebComponent - implements IToolbarSelectOption - { - __implements__sap_ui_webc_main_IToolbarSelectOption: boolean; - /** - * Constructor for a new `ToolbarSelectOption`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSelectOptionSettings - ); - /** - * Constructor for a new `ToolbarSelectOption`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSelectOptionSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ToolbarSelectOption with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ToolbarSelectOption. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the content of the control - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the content of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - } - /** - * Describes the settings that can be provided to the ToolbarSelectOption constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $ToolbarSelectOptionSettings extends $WebComponentSettings { - /** - * Defines the selected state of the component. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the content of the control - */ - text?: string | PropertyBindingInfo; - } -} - -declare module "sap/ui/webc/main/ToolbarSeparator" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IToolbarItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - /** - * Overview: The `sap.ui.webc.main.ToolbarSeparator` is an element, used for visual separation between two - * elements. It takes no space in calculating toolbar items width. - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class ToolbarSeparator - extends WebComponent - implements IToolbarItem - { - __implements__sap_ui_webc_main_IToolbarItem: boolean; - /** - * Constructor for a new `ToolbarSeparator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - * - * This class does not have its own settings, but all settings applicable to the base type {@link sap.ui.core.webc.WebComponent#constructor sap.ui.core.webc.WebComponent } - * can be used. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSeparatorSettings - ); - /** - * Constructor for a new `ToolbarSeparator`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - * - * This class does not have its own settings, but all settings applicable to the base type {@link sap.ui.core.webc.WebComponent#constructor sap.ui.core.webc.WebComponent } - * can be used. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSeparatorSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ToolbarSeparator with name `sClassName` and enriches - * it with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ToolbarSeparator. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - } - /** - * Describes the settings that can be provided to the ToolbarSeparator constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $ToolbarSeparatorSettings extends $WebComponentSettings {} -} - -declare module "sap/ui/webc/main/ToolbarSpacer" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { IToolbarItem } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { CSSSize } from "sap/ui/core/library"; - - import { PropertyBindingInfo } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.ToolbarSpacer` is an element, used for taking needed space for toolbar - * items to take 100% width. It takes no space in calculating toolbar items width. - * - * @since 1.120.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export default class ToolbarSpacer - extends WebComponent - implements IToolbarItem - { - __implements__sap_ui_webc_main_IToolbarItem: boolean; - /** - * Constructor for a new `ToolbarSpacer`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSpacerSettings - ); - /** - * Constructor for a new `ToolbarSpacer`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $ToolbarSpacerSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.ToolbarSpacer with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.ToolbarSpacer. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the spacer. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - * - * Default value is `undefined`. - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the spacer. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `undefined`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth?: CSSSize - ): this; - } - /** - * Describes the settings that can be provided to the ToolbarSpacer constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.120.0. This control is experimental and its API might change significantly. - */ - export interface $ToolbarSpacerSettings extends $WebComponentSettings { - /** - * Defines the width of the spacer. - * - * - * - * **Note:** all CSS sizes are supported - 'percentage', 'px', 'rem', 'auto', etc. - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - } -} - -declare module "sap/ui/webc/main/Tree" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ID, CSSSize } from "sap/ui/core/library"; - - import Control from "sap/ui/core/Control"; - - import { ITreeItem, ListMode } from "sap/ui/webc/main/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - import Event from "sap/ui/base/Event"; - - /** - * Overview: The `sap.ui.webc.main.Tree` component provides a tree structure for displaying data in a hierarchy. - * - * Usage: - * - * When to use:: - * - To display hierarchically structured items. - * - To select one or more items out of a set of hierarchically structured items. - * - * When not to use:: - * - To display items not hierarchically strcutured. In this case, use the List component. - * - To select one item from a very small number of non-hierarchical items. Select or ComboBox might be - * more appropriate. - * - The hierarchy turns out to have only two levels. In this case, use List with group items. - * - * Keyboard Handling: - * - * The `sap.ui.webc.main.Tree` provides advanced keyboard handling. The user can use the following keyboard - * shortcuts in order to navigate trough the tree: - * - [UP/DOWN] - Navigates up and down the tree items that are currently visible. - * - [RIGHT] - Drills down the tree by expanding the tree nodes. - * - [LEFT] - Goes up the tree and collapses the tree nodes. - * - * - * The user can use the following keyboard shortcuts to perform selection, when the `mode` property is in - * use: - * - [SPACE] - Selects the currently focused item upon keyup. - * - [ENTER] - Selects the currently focused item upon keydown. - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class Tree extends WebComponent { - /** - * Constructor for a new `Tree`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TreeSettings - ); - /** - * Constructor for a new `Tree`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TreeSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.Tree with name `sClassName` and enriches it with the - * information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.Tree. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some ariaLabelledBy into the association {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addAriaLabelledBy( - /** - * The ariaLabelledBy to add; if empty, nothing is inserted - */ - vAriaLabelledBy: ID | Control - ): this; - /** - * Adds some header to the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addHeader( - /** - * The header to add; if empty, nothing is inserted - */ - oHeader: Control - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ITreeItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when a tree item is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when a tree item is activated. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemClickEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when the Delete button of any tree item is pressed. - * - * **Note:** A Delete button is displayed on each item, when the component `mode` property is set to `Delete`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemDelete( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when the Delete button of any tree item is pressed. - * - * **Note:** A Delete button is displayed on each item, when the component `mode` property is set to `Delete`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemDelete( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemDeleteEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemMouseout itemMouseout} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when the mouse cursor leaves the tree item borders. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemMouseout( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemMouseoutEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemMouseout itemMouseout} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when the mouse cursor leaves the tree item borders. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemMouseout( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemMouseoutEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemMouseover itemMouseover} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when the mouse cursor enters the tree item borders. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemMouseover( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemMouseoverEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemMouseover itemMouseover} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when the mouse cursor enters the tree item borders. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemMouseover( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemMouseoverEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemToggle itemToggle} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when a tree item is expanded or collapsed. Note: You can call `preventDefault()` on the - * event object to suppress the event, if needed. This may be handy for example if you want to dynamically - * load tree items upon the user expanding a node. Even if you prevented the event's default behavior, you - * can always manually call `toggle()` on a tree item. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemToggle( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemToggleEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:itemToggle itemToggle} event of this `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when a tree item is expanded or collapsed. Note: You can call `preventDefault()` on the - * event object to suppress the event, if needed. This may be handy for example if you want to dynamically - * load tree items upon the user expanding a node. Even if you prevented the event's default behavior, you - * can always manually call `toggle()` on a tree item. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachItemToggle( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$ItemToggleEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd` - * and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:selectionChange selectionChange} event of this - * `sap.ui.webc.main.Tree`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.Tree` itself. - * - * Fired when selection is changed by user interaction in `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd` - * and `MultiSelect` modes. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachSelectionChange( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Tree$SelectionChangeEvent) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.Tree` itself - */ - oListener?: object - ): this; - /** - * Destroys all the header in the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyHeader(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemClick itemClick} event of this `sap.ui.webc.main.Tree`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Tree$ItemClickEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemDelete itemDelete} event of this `sap.ui.webc.main.Tree`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemDelete( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Tree$ItemDeleteEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemMouseout itemMouseout} event of this `sap.ui.webc.main.Tree`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemMouseout( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Tree$ItemMouseoutEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemMouseover itemMouseover} event of this - * `sap.ui.webc.main.Tree`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemMouseover( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Tree$ItemMouseoverEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:itemToggle itemToggle} event of this `sap.ui.webc.main.Tree`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachItemToggle( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Tree$ItemToggleEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:selectionChange selectionChange} event of - * this `sap.ui.webc.main.Tree`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachSelectionChange( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Tree$SelectionChangeEvent) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:itemClick itemClick} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireItemClick( - /** - * Parameters to pass along with the event - */ - mParameters?: Tree$ItemClickEventParameters - ): boolean; - /** - * Fires event {@link #event:itemDelete itemDelete} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemDelete( - /** - * Parameters to pass along with the event - */ - mParameters?: Tree$ItemDeleteEventParameters - ): this; - /** - * Fires event {@link #event:itemMouseout itemMouseout} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemMouseout( - /** - * Parameters to pass along with the event - */ - mParameters?: Tree$ItemMouseoutEventParameters - ): this; - /** - * Fires event {@link #event:itemMouseover itemMouseover} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireItemMouseover( - /** - * Parameters to pass along with the event - */ - mParameters?: Tree$ItemMouseoverEventParameters - ): this; - /** - * Fires event {@link #event:itemToggle itemToggle} to attached listeners. - * - * Listeners may prevent the default action of this event by calling the `preventDefault` method on the - * event object. The return value of this method indicates whether the default action should be executed. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Whether or not to prevent the default action - */ - fireItemToggle( - /** - * Parameters to pass along with the event - */ - mParameters?: Tree$ItemToggleEventParameters - ): boolean; - /** - * Fires event {@link #event:selectionChange selectionChange} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireSelectionChange( - /** - * Parameters to pass along with the event - */ - mParameters?: Tree$SelectionChangeEventParameters - ): this; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Returns array of IDs of the elements which are the current targets of the association {@link #getAriaLabelledBy ariaLabelledBy}. - */ - getAriaLabelledBy(): ID[]; - /** - * Gets current value of property {@link #getFooterText footerText}. - * - * Defines the component footer text. - * - * Default value is `empty string`. - * - * - * @returns Value of property `footerText` - */ - getFooterText(): string; - /** - * Gets content of aggregation {@link #getHeader header}. - * - * Defines the component header. - * - * **Note:** When the `header` slot is set, the `headerText` property is ignored. - */ - getHeader(): Control[]; - /** - * Gets current value of property {@link #getHeaderText headerText}. - * - * Defines the component header text. - * - * **Note:** If the `header` slot is set, this property is ignored. - * - * Default value is `empty string`. - * - * - * @returns Value of property `headerText` - */ - getHeaderText(): string; - /** - * Gets current value of property {@link #getHeight height}. - * - * Defines the height of the control - * - * - * @returns Value of property `height` - */ - getHeight(): CSSSize; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the component. Tree items may have other tree items as children. - * - * **Note:** Use `sap.ui.webc.main.TreeItem` for the intended design. - */ - getItems(): ITreeItem[]; - /** - * Gets current value of property {@link #getMode mode}. - * - * Defines the mode of the component. Since the tree uses a `sap.ui.webc.main.List` to display its structure, - * the tree modes are exactly the same as the list modes, and are all applicable. - * - * - * - * **Note:** - * - * - * - `None` - * - `SingleSelect` - * - `SingleSelectBegin` - * - `SingleSelectEnd` - * - `MultiSelect` - * - `Delete` - * - * Default value is `None`. - * - * - * @returns Value of property `mode` - */ - getMode(): ListMode; - /** - * Gets current value of property {@link #getNoDataText noDataText}. - * - * Defines the text that is displayed when the component contains no items. - * - * Default value is `empty string`. - * - * - * @returns Value of property `noDataText` - */ - getNoDataText(): string; - /** - * Gets current value of property {@link #getWidth width}. - * - * Defines the width of the control - * - * - * @returns Value of property `width` - */ - getWidth(): CSSSize; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getHeader header}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfHeader( - /** - * The header whose index is looked for - */ - oHeader: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.main.ITreeItem` in the aggregation {@link #getItems items}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ITreeItem - ): int; - /** - * Inserts a header into the aggregation {@link #getHeader header}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertHeader( - /** - * The header to insert; if empty, nothing is inserted - */ - oHeader: Control, - /** - * The `0`-based index the header should be inserted at; for a negative value of `iIndex`, the header is - * inserted at position 0; for a value greater than the current size of the aggregation, the header is inserted - * at the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ITreeItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls in the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllAriaLabelledBy(): ID[]; - /** - * Removes all the controls from the aggregation {@link #getHeader header}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllHeader(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ITreeItem[]; - /** - * Removes an ariaLabelledBy from the association named {@link #getAriaLabelledBy ariaLabelledBy}. - * - * - * @returns The removed ariaLabelledBy or `null` - */ - removeAriaLabelledBy( - /** - * The ariaLabelledBy to be removed or its index or ID - */ - vAriaLabelledBy: int | ID | Control - ): ID | null; - /** - * Removes a header from the aggregation {@link #getHeader header}. - * - * - * @returns The removed header or `null` - */ - removeHeader( - /** - * The header to remove or its index or id - */ - vHeader: int | string | Control - ): Control | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ITreeItem - ): ITreeItem | null; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getFooterText footerText}. - * - * Defines the component footer text. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setFooterText( - /** - * New value for property `footerText` - */ - sFooterText?: string - ): this; - /** - * Sets a new value for property {@link #getHeaderText headerText}. - * - * Defines the component header text. - * - * **Note:** If the `header` slot is set, this property is ignored. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeaderText( - /** - * New value for property `headerText` - */ - sHeaderText?: string - ): this; - /** - * Sets a new value for property {@link #getHeight height}. - * - * Defines the height of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHeight( - /** - * New value for property `height` - */ - sHeight: CSSSize - ): this; - /** - * Sets a new value for property {@link #getMode mode}. - * - * Defines the mode of the component. Since the tree uses a `sap.ui.webc.main.List` to display its structure, - * the tree modes are exactly the same as the list modes, and are all applicable. - * - * - * - * **Note:** - * - * - * - `None` - * - `SingleSelect` - * - `SingleSelectBegin` - * - `SingleSelectEnd` - * - `MultiSelect` - * - `Delete` - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setMode( - /** - * New value for property `mode` - */ - sMode?: ListMode | keyof typeof ListMode - ): this; - /** - * Sets a new value for property {@link #getNoDataText noDataText}. - * - * Defines the text that is displayed when the component contains no items. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNoDataText( - /** - * New value for property `noDataText` - */ - sNoDataText?: string - ): this; - /** - * Sets a new value for property {@link #getWidth width}. - * - * Defines the width of the control - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setWidth( - /** - * New value for property `width` - */ - sWidth: CSSSize - ): this; - /** - * Perform Depth-First-Search walk on the tree and run a callback on each node - */ - walk( - /** - * function to execute on each node of the tree with 3 arguments: the node, the level and the index - */ - callback: Function - ): void; - } - /** - * Describes the settings that can be provided to the Tree constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TreeSettings extends $WebComponentSettings { - /** - * Defines the accessible name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the component footer text. - */ - footerText?: string | PropertyBindingInfo; - - /** - * Defines the component header text. - * - * **Note:** If the `header` slot is set, this property is ignored. - */ - headerText?: string | PropertyBindingInfo; - - /** - * Defines the height of the control - */ - height?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the mode of the component. Since the tree uses a `sap.ui.webc.main.List` to display its structure, - * the tree modes are exactly the same as the list modes, and are all applicable. - * - * - * - * **Note:** - * - * - * - `None` - * - `SingleSelect` - * - `SingleSelectBegin` - * - `SingleSelectEnd` - * - `MultiSelect` - * - `Delete` - */ - mode?: - | (ListMode | keyof typeof ListMode) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the text that is displayed when the component contains no items. - */ - noDataText?: string | PropertyBindingInfo; - - /** - * Defines the width of the control - */ - width?: CSSSize | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the component header. - * - * **Note:** When the `header` slot is set, the `headerText` property is ignored. - */ - header?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the items of the component. Tree items may have other tree items as children. - * - * **Note:** Use `sap.ui.webc.main.TreeItem` for the intended design. - */ - items?: ITreeItem[] | ITreeItem | AggregationBindingInfo | `{${string}}`; - - /** - * Receives id(or many ids) of the controls that label this control. - */ - ariaLabelledBy?: Array; - - /** - * Fired when a tree item is activated. - */ - itemClick?: (oEvent: Tree$ItemClickEvent) => void; - - /** - * Fired when the Delete button of any tree item is pressed. - * - * **Note:** A Delete button is displayed on each item, when the component `mode` property is set to `Delete`. - */ - itemDelete?: (oEvent: Tree$ItemDeleteEvent) => void; - - /** - * Fired when the mouse cursor leaves the tree item borders. - */ - itemMouseout?: (oEvent: Tree$ItemMouseoutEvent) => void; - - /** - * Fired when the mouse cursor enters the tree item borders. - */ - itemMouseover?: (oEvent: Tree$ItemMouseoverEvent) => void; - - /** - * Fired when a tree item is expanded or collapsed. Note: You can call `preventDefault()` on the - * event object to suppress the event, if needed. This may be handy for example if you want to dynamically - * load tree items upon the user expanding a node. Even if you prevented the event's default behavior, you - * can always manually call `toggle()` on a tree item. - */ - itemToggle?: (oEvent: Tree$ItemToggleEvent) => void; - - /** - * Fired when selection is changed by user interaction in `SingleSelect`, `SingleSelectBegin`, `SingleSelectEnd` - * and `MultiSelect` modes. - */ - selectionChange?: (oEvent: Tree$SelectionChangeEvent) => void; - } - - /** - * Parameters of the Tree#itemClick event. - */ - export interface Tree$ItemClickEventParameters { - /** - * The clicked item. - */ - item?: HTMLElement; - } - - /** - * Event object of the Tree#itemClick event. - */ - export type Tree$ItemClickEvent = Event; - - /** - * Parameters of the Tree#itemDelete event. - */ - export interface Tree$ItemDeleteEventParameters { - /** - * the deleted item. - */ - item?: HTMLElement; - } - - /** - * Event object of the Tree#itemDelete event. - */ - export type Tree$ItemDeleteEvent = Event< - Tree$ItemDeleteEventParameters, - Tree - >; - - /** - * Parameters of the Tree#itemMouseout event. - */ - export interface Tree$ItemMouseoutEventParameters { - /** - * the hovered item. - */ - item?: HTMLElement; - } - - /** - * Event object of the Tree#itemMouseout event. - */ - export type Tree$ItemMouseoutEvent = Event< - Tree$ItemMouseoutEventParameters, - Tree - >; - - /** - * Parameters of the Tree#itemMouseover event. - */ - export interface Tree$ItemMouseoverEventParameters { - /** - * the hovered item. - */ - item?: HTMLElement; - } - - /** - * Event object of the Tree#itemMouseover event. - */ - export type Tree$ItemMouseoverEvent = Event< - Tree$ItemMouseoverEventParameters, - Tree - >; - - /** - * Parameters of the Tree#itemToggle event. - */ - export interface Tree$ItemToggleEventParameters { - /** - * the toggled item. - */ - item?: HTMLElement; - } - - /** - * Event object of the Tree#itemToggle event. - */ - export type Tree$ItemToggleEvent = Event< - Tree$ItemToggleEventParameters, - Tree - >; - - /** - * Parameters of the Tree#selectionChange event. - */ - export interface Tree$SelectionChangeEventParameters { - /** - * An array of the selected items. - */ - selectedItems?: any[]; - - /** - * An array of the previously selected items. - */ - previouslySelectedItems?: any[]; - - /** - * The item triggering the event. - */ - targetItem?: HTMLElement; - } - - /** - * Event object of the Tree#selectionChange event. - */ - export type Tree$SelectionChangeEvent = Event< - Tree$SelectionChangeEventParameters, - Tree - >; -} - -declare module "sap/ui/webc/main/TreeItem" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITreeItem, IButton, ListItemType } from "sap/ui/webc/main/library"; - - import Event from "sap/ui/base/Event"; - - import { ValueState } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * Overview: The `sap.ui.webc.main.TreeItem` represents a node in a tree structure, shown as a `sap.ui.webc.main.List`. - * - * This is the item to use inside a `sap.ui.webc.main.Tree`. You can represent an arbitrary tree structure - * by recursively nesting tree items. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TreeItem` exposes the following CSS Shadow Parts: - * - title - Used to style the title of the tree list item - * - additionalText - Used to style the additionalText of the tree list item - * - icon - Used to style the icon of the tree list item - * - * @since 1.92.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export default class TreeItem extends WebComponent implements ITreeItem { - __implements__sap_ui_webc_main_ITreeItem: boolean; - /** - * Constructor for a new `TreeItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TreeItemSettings - ); - /** - * Constructor for a new `TreeItem`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TreeItemSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TreeItem with name `sClassName` and enriches it with - * the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TreeItem. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ITreeItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.TreeItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TreeItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TreeItem` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.TreeItem`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TreeItem` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TreeItem` itself - */ - oListener?: object - ): this; - /** - * Destroys the deleteButton in the aggregation {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyDeleteButton(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.TreeItem`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachDetailClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:detailClick detailClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireDetailClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the tree item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `additionalText` - */ - getAdditionalText(): string; - /** - * Gets current value of property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - * - * Default value is `None`. - * - * - * @returns Value of property `additionalTextState` - */ - getAdditionalTextState(): ValueState; - /** - * Gets content of aggregation {@link #getDeleteButton deleteButton}. - * - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - getDeleteButton(): IButton; - /** - * Gets current value of property {@link #getExpanded expanded}. - * - * Defines whether the tree list item will show a collapse or expand icon inside its toggle button. - * - * Default value is `false`. - * - * - * @returns Value of property `expanded` - */ - getExpanded(): boolean; - /** - * Gets current value of property {@link #getHasChildren hasChildren}. - * - * Defines whether the tree node has children, even if currently no other tree nodes are slotted inside. - * - * Note: This property is useful for showing big tree structures where not all nodes are initially - * loaded due to performance reasons. Set this to `true` for nodes you intend to load lazily, when the user - * clicks the expand button. It is not necessary to set this property otherwise. If a tree item has children, - * the expand button will be displayed anyway. - * - * Default value is `false`. - * - * - * @returns Value of property `hasChildren` - */ - getHasChildren(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * If set, an icon will be displayed before the text of the tree list item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIndeterminate indeterminate}. - * - * Defines whether the selection of a tree node is displayed as partially selected. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction, - * meaning that the resulting visual state depends on the values of the `indeterminate` and `selected` properties: - * - * If a tree node has both `selected` and `indeterminate` set to `true`, it is displayed as partially - * selected. If a tree node has `selected` set to `true` and `indeterminate` set to `false`, it is - * displayed as selected. If a tree node has `selected` set to `false`, it is displayed as not selected - * regardless of the value of the `indeterminate` property. - * **Note:** This property takes effect only when the `sap.ui.webc.main.Tree` is in `MultiSelect` mode. - * - * Default value is `false`. - * - * - * @returns Value of property `indeterminate` - */ - getIndeterminate(): boolean; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the component. **Note:** Use `sap.ui.webc.main.TreeItem` or `sap.ui.webc.main.TreeItemCustom` - */ - getItems(): ITreeItem[]; - /** - * Gets current value of property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * - * @returns Value of property `navigated` - */ - getNavigated(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getText text}. - * - * Defines the text of the tree item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `text` - */ - getText(): string; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * Default value is `Active`. - * - * - * @returns Value of property `type` - */ - getType(): ListItemType; - /** - * Checks for the provided `sap.ui.webc.main.ITreeItem` in the aggregation {@link #getItems items}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ITreeItem - ): int; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ITreeItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ITreeItem[]; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ITreeItem - ): ITreeItem | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getAdditionalText additionalText}. - * - * Defines the `additionalText`, displayed in the end of the tree item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalText( - /** - * New value for property `additionalText` - */ - sAdditionalText?: string - ): this; - /** - * Sets a new value for property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalTextState( - /** - * New value for property `additionalTextState` - */ - sAdditionalTextState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets the aggregated {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDeleteButton( - /** - * The deleteButton to set - */ - oDeleteButton: IButton - ): this; - /** - * Sets a new value for property {@link #getExpanded expanded}. - * - * Defines whether the tree list item will show a collapse or expand icon inside its toggle button. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setExpanded( - /** - * New value for property `expanded` - */ - bExpanded?: boolean - ): this; - /** - * Sets a new value for property {@link #getHasChildren hasChildren}. - * - * Defines whether the tree node has children, even if currently no other tree nodes are slotted inside. - * - * Note: This property is useful for showing big tree structures where not all nodes are initially - * loaded due to performance reasons. Set this to `true` for nodes you intend to load lazily, when the user - * clicks the expand button. It is not necessary to set this property otherwise. If a tree item has children, - * the expand button will be displayed anyway. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHasChildren( - /** - * New value for property `hasChildren` - */ - bHasChildren?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * If set, an icon will be displayed before the text of the tree list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getIndeterminate indeterminate}. - * - * Defines whether the selection of a tree node is displayed as partially selected. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction, - * meaning that the resulting visual state depends on the values of the `indeterminate` and `selected` properties: - * - * If a tree node has both `selected` and `indeterminate` set to `true`, it is displayed as partially - * selected. If a tree node has `selected` set to `true` and `indeterminate` set to `false`, it is - * displayed as selected. If a tree node has `selected` set to `false`, it is displayed as not selected - * regardless of the value of the `indeterminate` property. - * **Note:** This property takes effect only when the `sap.ui.webc.main.Tree` is in `MultiSelect` mode. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIndeterminate( - /** - * New value for property `indeterminate` - */ - bIndeterminate?: boolean - ): this; - /** - * Sets a new value for property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNavigated( - /** - * New value for property `navigated` - */ - bNavigated: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getText text}. - * - * Defines the text of the tree item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setText( - /** - * New value for property `text` - */ - sText?: string - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Active`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ListItemType | keyof typeof ListItemType - ): this; - /** - * Call this method to manually switch the `expanded` state of a tree item. - */ - toggle(): void; - } - /** - * Describes the settings that can be provided to the TreeItem constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.92.0. This control is experimental and its API might change significantly. - */ - export interface $TreeItemSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the accessible name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the `additionalText`, displayed in the end of the tree item. - */ - additionalText?: string | PropertyBindingInfo; - - /** - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - */ - additionalTextState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the tree list item will show a collapse or expand icon inside its toggle button. - */ - expanded?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the tree node has children, even if currently no other tree nodes are slotted inside. - * - * Note: This property is useful for showing big tree structures where not all nodes are initially - * loaded due to performance reasons. Set this to `true` for nodes you intend to load lazily, when the user - * clicks the expand button. It is not necessary to set this property otherwise. If a tree item has children, - * the expand button will be displayed anyway. - */ - hasChildren?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * If set, an icon will be displayed before the text of the tree list item. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the selection of a tree node is displayed as partially selected. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction, - * meaning that the resulting visual state depends on the values of the `indeterminate` and `selected` properties: - * - * If a tree node has both `selected` and `indeterminate` set to `true`, it is displayed as partially - * selected. If a tree node has `selected` set to `true` and `indeterminate` set to `false`, it is - * displayed as selected. If a tree node has `selected` set to `false`, it is displayed as not selected - * regardless of the value of the `indeterminate` property. - * **Note:** This property takes effect only when the `sap.ui.webc.main.Tree` is in `MultiSelect` mode. - */ - indeterminate?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - */ - navigated?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the text of the tree item. - */ - text?: string | PropertyBindingInfo; - - /** - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - */ - type?: - | (ListItemType | keyof typeof ListItemType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - deleteButton?: IButton; - - /** - * Defines the items of the component. **Note:** Use `sap.ui.webc.main.TreeItem` or `sap.ui.webc.main.TreeItemCustom` - */ - items?: ITreeItem[] | ITreeItem | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the user clicks on the detail button when type is `Detail`. - */ - detailClick?: (oEvent: Event) => void; - } - - /** - * Parameters of the TreeItem#detailClick event. - */ - export interface TreeItem$DetailClickEventParameters {} - - /** - * Event object of the TreeItem#detailClick event. - */ - export type TreeItem$DetailClickEvent = Event< - TreeItem$DetailClickEventParameters, - TreeItem - >; -} - -declare module "sap/ui/webc/main/TreeItemCustom" { - import { - default as WebComponent, - $WebComponentSettings, - } from "sap/ui/core/webc/WebComponent"; - - import { ITreeItem, IButton, ListItemType } from "sap/ui/webc/main/library"; - - import Control from "sap/ui/core/Control"; - - import Event from "sap/ui/base/Event"; - - import { ValueState } from "sap/ui/core/library"; - - import WebComponentMetadata from "sap/ui/core/webc/WebComponentMetadata"; - - import { - PropertyBindingInfo, - AggregationBindingInfo, - } from "sap/ui/base/ManagedObject"; - - /** - * The `sap.ui.webc.main.TreeItemCustom` represents a node in a tree structure, shown as a `sap.ui.webc.main.List`. - * - * This is the item to use inside a `sap.ui.webc.main.Tree`. You can represent an arbitrary tree structure - * by recursively nesting tree items. - * - * You can use this item to put any custom content inside the tree item. - * - * CSS Shadow Parts: - * - * {@link https://developer.mozilla.org/en-US/docs/Web/CSS/::part CSS Shadow Parts} allow developers to - * style elements inside the Shadow DOM. - * The `sap.ui.webc.main.TreeItemCustom` exposes the following CSS Shadow Parts: - * - title - Used to style the title of the tree list item - * - additionalText - Used to style the additionalText of the tree list item - * - icon - Used to style the icon of the tree list item - * - * @since 1.115.0 - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.115.0. This control is experimental and its API might change significantly. - */ - export default class TreeItemCustom - extends WebComponent - implements ITreeItem - { - __implements__sap_ui_webc_main_ITreeItem: boolean; - /** - * Constructor for a new `TreeItemCustom`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * Initial settings for the new control - */ - mSettings?: $TreeItemCustomSettings - ); - /** - * Constructor for a new `TreeItemCustom`. - * - * Accepts an object literal `mSettings` that defines initial property values, aggregated and associated - * objects as well as event handlers. See {@link sap.ui.base.ManagedObject#constructor} for a general description - * of the syntax of the settings object. - */ - constructor( - /** - * ID for the new control, generated automatically if no ID is given - */ - sId?: string, - /** - * Initial settings for the new control - */ - mSettings?: $TreeItemCustomSettings - ); - - /** - * Creates a new subclass of class sap.ui.webc.main.TreeItemCustom with name `sClassName` and enriches it - * with the information contained in `oClassInfo`. - * - * `oClassInfo` might contain the same kind of information as described in {@link sap.ui.core.webc.WebComponent.extend}. - * - * - * @returns Created class / constructor function - */ - static extend>( - /** - * Name of the class being created - */ - sClassName: string, - /** - * Object literal with information about the class - */ - oClassInfo?: sap.ClassInfo, - /** - * Constructor function for the metadata object; if not given, it defaults to the metadata implementation - * used by this class - */ - FNMetaImpl?: Function - ): Function; - /** - * Returns a metadata object for class sap.ui.webc.main.TreeItemCustom. - * - * - * @returns Metadata object describing this class - */ - static getMetadata(): WebComponentMetadata; - /** - * Adds some content to the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addContent( - /** - * The content to add; if empty, nothing is inserted - */ - oContent: Control - ): this; - /** - * Adds some item to the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - addItem( - /** - * The item to add; if empty, nothing is inserted - */ - oItem: ITreeItem - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.TreeItemCustom`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TreeItemCustom` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * An application-specific payload object that will be passed to the event handler along with the event - * object when firing the event - */ - oData: object, - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TreeItemCustom` itself - */ - oListener?: object - ): this; - /** - * Attaches event handler `fnFunction` to the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.TreeItemCustom`. - * - * When called, the context of the event handler (its `this`) will be bound to `oListener` if specified, - * otherwise it will be bound to this `sap.ui.webc.main.TreeItemCustom` itself. - * - * Fired when the user clicks on the detail button when type is `Detail`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - attachDetailClick( - /** - * The function to be called when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object to call the event handler with. Defaults to this `sap.ui.webc.main.TreeItemCustom` itself - */ - oListener?: object - ): this; - /** - * Destroys all the content in the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyContent(): this; - /** - * Destroys the deleteButton in the aggregation {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyDeleteButton(): this; - /** - * Destroys all the items in the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - destroyItems(): this; - /** - * Detaches event handler `fnFunction` from the {@link #event:detailClick detailClick} event of this `sap.ui.webc.main.TreeItemCustom`. - * - * The passed function and listener object must match the ones used for event registration. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - detachDetailClick( - /** - * The function to be called, when the event occurs - */ - fnFunction: (p1: Event) => void, - /** - * Context object on which the given function had to be called - */ - oListener?: object - ): this; - /** - * Fires event {@link #event:detailClick detailClick} to attached listeners. - * - * @ui5-protected Do not call from applications (only from related classes in the framework) - * - * @returns Reference to `this` in order to allow method chaining - */ - fireDetailClick( - /** - * Parameters to pass along with the event - */ - mParameters?: object - ): this; - /** - * Gets current value of property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * Default value is `{}`. - * - * - * @returns Value of property `accessibilityAttributes` - */ - getAccessibilityAttributes(): object; - /** - * Gets current value of property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * - * @returns Value of property `accessibleName` - */ - getAccessibleName(): string; - /** - * Gets current value of property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - * - * Default value is `None`. - * - * - * @returns Value of property `additionalTextState` - */ - getAdditionalTextState(): ValueState; - /** - * Gets content of aggregation {@link #getContent content}. - * - * Defines the content of the `sap.ui.webc.main.TreeItem`. - */ - getContent(): Control[]; - /** - * Gets content of aggregation {@link #getDeleteButton deleteButton}. - * - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - getDeleteButton(): IButton; - /** - * Gets current value of property {@link #getExpanded expanded}. - * - * Defines whether the tree list item will show a collapse or expand icon inside its toggle button. - * - * Default value is `false`. - * - * - * @returns Value of property `expanded` - */ - getExpanded(): boolean; - /** - * Gets current value of property {@link #getHasChildren hasChildren}. - * - * Defines whether the tree node has children, even if currently no other tree nodes are slotted inside. - * - * Note: This property is useful for showing big tree structures where not all nodes are initially - * loaded due to performance reasons. Set this to `true` for nodes you intend to load lazily, when the user - * clicks the expand button. It is not necessary to set this property otherwise. If a tree item has children, - * the expand button will be displayed anyway. - * - * Default value is `false`. - * - * - * @returns Value of property `hasChildren` - */ - getHasChildren(): boolean; - /** - * Gets current value of property {@link #getHideSelectionElement hideSelectionElement}. - * - * Defines whether the tree list item should display the selection element. - * - * Default value is `false`. - * - * - * @returns Value of property `hideSelectionElement` - */ - getHideSelectionElement(): boolean; - /** - * Gets current value of property {@link #getIcon icon}. - * - * If set, an icon will be displayed before the text of the tree list item. - * - * Default value is `empty string`. - * - * - * @returns Value of property `icon` - */ - getIcon(): string; - /** - * Gets current value of property {@link #getIndeterminate indeterminate}. - * - * Defines whether the selection of a tree node is displayed as partially selected. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction, - * meaning that the resulting visual state depends on the values of the `indeterminate` and `selected` properties: - * - * If a tree node has both `selected` and `indeterminate` set to `true`, it is displayed as partially - * selected. If a tree node has `selected` set to `true` and `indeterminate` set to `false`, it is - * displayed as selected. If a tree node has `selected` set to `false`, it is displayed as not selected - * regardless of the value of the `indeterminate` property. - * **Note:** This property takes effect only when the `sap.ui.webc.main.Tree` is in `MultiSelect` mode. - * - * Default value is `false`. - * - * - * @returns Value of property `indeterminate` - */ - getIndeterminate(): boolean; - /** - * Gets content of aggregation {@link #getItems items}. - * - * Defines the items of the component. **Note:** Use `sap.ui.webc.main.TreeItem` or `sap.ui.webc.main.TreeItemCustom` - */ - getItems(): ITreeItem[]; - /** - * Gets current value of property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * - * @returns Value of property `navigated` - */ - getNavigated(): boolean; - /** - * Gets current value of property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * Default value is `false`. - * - * - * @returns Value of property `selected` - */ - getSelected(): boolean; - /** - * Gets current value of property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * Default value is `Active`. - * - * - * @returns Value of property `type` - */ - getType(): ListItemType; - /** - * Checks for the provided `sap.ui.core.Control` in the aggregation {@link #getContent content}. and returns - * its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfContent( - /** - * The content whose index is looked for - */ - oContent: Control - ): int; - /** - * Checks for the provided `sap.ui.webc.main.ITreeItem` in the aggregation {@link #getItems items}. and - * returns its index if found or -1 otherwise. - * - * - * @returns The index of the provided control in the aggregation if found, or -1 otherwise - */ - indexOfItem( - /** - * The item whose index is looked for - */ - oItem: ITreeItem - ): int; - /** - * Inserts a content into the aggregation {@link #getContent content}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertContent( - /** - * The content to insert; if empty, nothing is inserted - */ - oContent: Control, - /** - * The `0`-based index the content should be inserted at; for a negative value of `iIndex`, the content - * is inserted at position 0; for a value greater than the current size of the aggregation, the content - * is inserted at the last position - */ - iIndex: int - ): this; - /** - * Inserts a item into the aggregation {@link #getItems items}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - insertItem( - /** - * The item to insert; if empty, nothing is inserted - */ - oItem: ITreeItem, - /** - * The `0`-based index the item should be inserted at; for a negative value of `iIndex`, the item is inserted - * at position 0; for a value greater than the current size of the aggregation, the item is inserted at - * the last position - */ - iIndex: int - ): this; - /** - * Removes all the controls from the aggregation {@link #getContent content}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllContent(): Control[]; - /** - * Removes all the controls from the aggregation {@link #getItems items}. - * - * Additionally, it unregisters them from the hosting UIArea. - * - * - * @returns An array of the removed elements (might be empty) - */ - removeAllItems(): ITreeItem[]; - /** - * Removes a content from the aggregation {@link #getContent content}. - * - * - * @returns The removed content or `null` - */ - removeContent( - /** - * The content to remove or its index or id - */ - vContent: int | string | Control - ): Control | null; - /** - * Removes a item from the aggregation {@link #getItems items}. - * - * - * @returns The removed item or `null` - */ - removeItem( - /** - * The item to remove or its index or id - */ - vItem: int | string | ITreeItem - ): ITreeItem | null; - /** - * Sets a new value for property {@link #getAccessibilityAttributes accessibilityAttributes}. - * - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `{}`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibilityAttributes( - /** - * New value for property `accessibilityAttributes` - */ - oAccessibilityAttributes?: object - ): this; - /** - * Sets a new value for property {@link #getAccessibleName accessibleName}. - * - * Defines the accessible name of the component. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAccessibleName( - /** - * New value for property `accessibleName` - */ - sAccessibleName: string - ): this; - /** - * Sets a new value for property {@link #getAdditionalTextState additionalTextState}. - * - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `None`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setAdditionalTextState( - /** - * New value for property `additionalTextState` - */ - sAdditionalTextState?: ValueState | keyof typeof ValueState - ): this; - /** - * Sets the aggregated {@link #getDeleteButton deleteButton}. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setDeleteButton( - /** - * The deleteButton to set - */ - oDeleteButton: IButton - ): this; - /** - * Sets a new value for property {@link #getExpanded expanded}. - * - * Defines whether the tree list item will show a collapse or expand icon inside its toggle button. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setExpanded( - /** - * New value for property `expanded` - */ - bExpanded?: boolean - ): this; - /** - * Sets a new value for property {@link #getHasChildren hasChildren}. - * - * Defines whether the tree node has children, even if currently no other tree nodes are slotted inside. - * - * Note: This property is useful for showing big tree structures where not all nodes are initially - * loaded due to performance reasons. Set this to `true` for nodes you intend to load lazily, when the user - * clicks the expand button. It is not necessary to set this property otherwise. If a tree item has children, - * the expand button will be displayed anyway. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHasChildren( - /** - * New value for property `hasChildren` - */ - bHasChildren?: boolean - ): this; - /** - * Sets a new value for property {@link #getHideSelectionElement hideSelectionElement}. - * - * Defines whether the tree list item should display the selection element. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setHideSelectionElement( - /** - * New value for property `hideSelectionElement` - */ - bHideSelectionElement?: boolean - ): this; - /** - * Sets a new value for property {@link #getIcon icon}. - * - * If set, an icon will be displayed before the text of the tree list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `empty string`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIcon( - /** - * New value for property `icon` - */ - sIcon?: string - ): this; - /** - * Sets a new value for property {@link #getIndeterminate indeterminate}. - * - * Defines whether the selection of a tree node is displayed as partially selected. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction, - * meaning that the resulting visual state depends on the values of the `indeterminate` and `selected` properties: - * - * If a tree node has both `selected` and `indeterminate` set to `true`, it is displayed as partially - * selected. If a tree node has `selected` set to `true` and `indeterminate` set to `false`, it is - * displayed as selected. If a tree node has `selected` set to `false`, it is displayed as not selected - * regardless of the value of the `indeterminate` property. - * **Note:** This property takes effect only when the `sap.ui.webc.main.Tree` is in `MultiSelect` mode. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setIndeterminate( - /** - * New value for property `indeterminate` - */ - bIndeterminate?: boolean - ): this; - /** - * Sets a new value for property {@link #getNavigated navigated}. - * - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setNavigated( - /** - * New value for property `navigated` - */ - bNavigated: boolean - ): this; - /** - * Sets a new value for property {@link #getSelected selected}. - * - * Defines the selected state of the `ListItem`. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `false`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setSelected( - /** - * New value for property `selected` - */ - bSelected?: boolean - ): this; - /** - * Sets a new value for property {@link #getType type}. - * - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - * - * When called with a value of `null` or `undefined`, the default value of the property will be restored. - * - * Default value is `Active`. - * - * - * @returns Reference to `this` in order to allow method chaining - */ - setType( - /** - * New value for property `type` - */ - sType?: ListItemType | keyof typeof ListItemType - ): this; - /** - * Call this method to manually switch the `expanded` state of a tree item. - */ - toggle(): void; - } - /** - * Describes the settings that can be provided to the TreeItemCustom constructor. - * - * @deprecated As of version 1.120. this Web Components consumption model has been discarded. Until an alternative - * Web Components consumption model is available in the future, use sap.m and sap.f controls with similar - * functionality. - * @experimental As of version 1.115.0. This control is experimental and its API might change significantly. - */ - export interface $TreeItemCustomSettings extends $WebComponentSettings { - /** - * An object of strings that defines several additional accessibility attribute values for customization - * depending on the use case. - * - * It supports the following fields: - * - * - * - `ariaSetsize`: Defines the number of items in the current set of listitems or treeitems when not - * all items in the set are present in the DOM. The value of each `aria-setsize` is an integer reflecting - * number of items in the complete set. **Note: ** If the size of the entire set is unknown, set `aria-setsize="-1"`. - * - * - `ariaPosinset`: Defines an element's number or position in the current set of listitems or treeitems - * when not all items are present in the DOM. The value of each `aria-posinset` is an integer greater than - * or equal to 1, and less than or equal to the size of the set when that size is known. - */ - accessibilityAttributes?: object | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the accessible name of the component. - */ - accessibleName?: string | PropertyBindingInfo; - - /** - * Defines the state of the `additionalText`. - * Available options are: `"None"` (by default), `"Success"`, `"Warning"`, `"Information"` and `"Error"`. - */ - additionalTextState?: - | (ValueState | keyof typeof ValueState) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines whether the tree list item will show a collapse or expand icon inside its toggle button. - */ - expanded?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the tree node has children, even if currently no other tree nodes are slotted inside. - * - * Note: This property is useful for showing big tree structures where not all nodes are initially - * loaded due to performance reasons. Set this to `true` for nodes you intend to load lazily, when the user - * clicks the expand button. It is not necessary to set this property otherwise. If a tree item has children, - * the expand button will be displayed anyway. - */ - hasChildren?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines whether the tree list item should display the selection element. - */ - hideSelectionElement?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * If set, an icon will be displayed before the text of the tree list item. - */ - icon?: string | PropertyBindingInfo; - - /** - * Defines whether the selection of a tree node is displayed as partially selected. - * - * **Note:** The indeterminate state can be set only programmatically and can’t be achieved by user interaction, - * meaning that the resulting visual state depends on the values of the `indeterminate` and `selected` properties: - * - * If a tree node has both `selected` and `indeterminate` set to `true`, it is displayed as partially - * selected. If a tree node has `selected` set to `true` and `indeterminate` set to `false`, it is - * displayed as selected. If a tree node has `selected` set to `false`, it is displayed as not selected - * regardless of the value of the `indeterminate` property. - * **Note:** This property takes effect only when the `sap.ui.webc.main.Tree` is in `MultiSelect` mode. - */ - indeterminate?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * The navigated state of the list item. If set to `true`, a navigation indicator is displayed at the end - * of the list item. - */ - navigated?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the selected state of the `ListItem`. - */ - selected?: boolean | PropertyBindingInfo | `{${string}}`; - - /** - * Defines the visual indication and behavior of the list items. Available options are `Active` (by default), - * `Inactive`, `Detail` and `Navigation`. - * - * **Note:** When set to `Active` or `Navigation`, the item will provide visual response upon press and - * hover, while with type `Inactive` and `Detail` - will not. - */ - type?: - | (ListItemType | keyof typeof ListItemType) - | PropertyBindingInfo - | `{${string}}`; - - /** - * Defines the content of the `sap.ui.webc.main.TreeItem`. - */ - content?: Control[] | Control | AggregationBindingInfo | `{${string}}`; - - /** - * Defines the delete button, displayed in "Delete" mode. **Note:** While the slot allows custom buttons, - * to match design guidelines, please use the `sap.ui.webc.main.Button` component. **Note:** When the slot - * is not present, a built-in delete button will be displayed. - */ - deleteButton?: IButton; - - /** - * Defines the items of the component. **Note:** Use `sap.ui.webc.main.TreeItem` or `sap.ui.webc.main.TreeItemCustom` - */ - items?: ITreeItem[] | ITreeItem | AggregationBindingInfo | `{${string}}`; - - /** - * Fired when the user clicks on the detail button when type is `Detail`. - */ - detailClick?: (oEvent: Event) => void; - } - - /** - * Parameters of the TreeItemCustom#detailClick event. - */ - export interface TreeItemCustom$DetailClickEventParameters {} - - /** - * Event object of the TreeItemCustom#detailClick event. - */ - export type TreeItemCustom$DetailClickEvent = Event< - TreeItemCustom$DetailClickEventParameters, - TreeItemCustom - >; -} - -declare namespace sap { - interface IUI5DefineDependencyNames { - "sap/ui/webc/main/Avatar": undefined; - - "sap/ui/webc/main/AvatarGroup": undefined; - - "sap/ui/webc/main/Badge": undefined; - - "sap/ui/webc/main/Breadcrumbs": undefined; - - "sap/ui/webc/main/BreadcrumbsItem": undefined; - - "sap/ui/webc/main/BusyIndicator": undefined; - - "sap/ui/webc/main/Button": undefined; - - "sap/ui/webc/main/Calendar": undefined; - - "sap/ui/webc/main/CalendarDate": undefined; - - "sap/ui/webc/main/Card": undefined; - - "sap/ui/webc/main/CardHeader": undefined; - - "sap/ui/webc/main/Carousel": undefined; - - "sap/ui/webc/main/CheckBox": undefined; - - "sap/ui/webc/main/ColorPalette": undefined; - - "sap/ui/webc/main/ColorPaletteItem": undefined; - - "sap/ui/webc/main/ColorPalettePopover": undefined; - - "sap/ui/webc/main/ColorPicker": undefined; - - "sap/ui/webc/main/ComboBox": undefined; - - "sap/ui/webc/main/ComboBoxGroupItem": undefined; - - "sap/ui/webc/main/ComboBoxItem": undefined; - - "sap/ui/webc/main/CustomListItem": undefined; - - "sap/ui/webc/main/DatePicker": undefined; - - "sap/ui/webc/main/DateRangePicker": undefined; - - "sap/ui/webc/main/DateTimePicker": undefined; - - "sap/ui/webc/main/Dialog": undefined; - - "sap/ui/webc/main/FileUploader": undefined; - - "sap/ui/webc/main/GroupHeaderListItem": undefined; - - "sap/ui/webc/main/Icon": undefined; - - "sap/ui/webc/main/Input": undefined; - - "sap/ui/webc/main/Label": undefined; - - "sap/ui/webc/main/library": undefined; - - "sap/ui/webc/main/Link": undefined; - - "sap/ui/webc/main/List": undefined; - - "sap/ui/webc/main/Menu": undefined; - - "sap/ui/webc/main/MenuItem": undefined; - - "sap/ui/webc/main/MessageStrip": undefined; - - "sap/ui/webc/main/MultiComboBox": undefined; - - "sap/ui/webc/main/MultiComboBoxGroupItem": undefined; - - "sap/ui/webc/main/MultiComboBoxItem": undefined; - - "sap/ui/webc/main/MultiInput": undefined; - - "sap/ui/webc/main/Option": undefined; - - "sap/ui/webc/main/Panel": undefined; - - "sap/ui/webc/main/Popover": undefined; - - "sap/ui/webc/main/ProgressIndicator": undefined; - - "sap/ui/webc/main/RadioButton": undefined; - - "sap/ui/webc/main/RangeSlider": undefined; - - "sap/ui/webc/main/RatingIndicator": undefined; - - "sap/ui/webc/main/ResponsivePopover": undefined; - - "sap/ui/webc/main/SegmentedButton": undefined; - - "sap/ui/webc/main/SegmentedButtonItem": undefined; - - "sap/ui/webc/main/Select": undefined; - - "sap/ui/webc/main/SelectMenu": undefined; - - "sap/ui/webc/main/SelectMenuOption": undefined; - - "sap/ui/webc/main/Slider": undefined; - - "sap/ui/webc/main/SplitButton": undefined; - - "sap/ui/webc/main/StandardListItem": undefined; - - "sap/ui/webc/main/StepInput": undefined; - - "sap/ui/webc/main/SuggestionGroupItem": undefined; - - "sap/ui/webc/main/SuggestionItem": undefined; - - "sap/ui/webc/main/Switch": undefined; - - "sap/ui/webc/main/Tab": undefined; - - "sap/ui/webc/main/TabContainer": undefined; - - "sap/ui/webc/main/Table": undefined; - - "sap/ui/webc/main/TableCell": undefined; - - "sap/ui/webc/main/TableColumn": undefined; - - "sap/ui/webc/main/TableGroupRow": undefined; - - "sap/ui/webc/main/TableRow": undefined; - - "sap/ui/webc/main/TabSeparator": undefined; - - "sap/ui/webc/main/TextArea": undefined; - - "sap/ui/webc/main/TimePicker": undefined; - - "sap/ui/webc/main/Title": undefined; - - "sap/ui/webc/main/Toast": undefined; - - "sap/ui/webc/main/ToggleButton": undefined; - - "sap/ui/webc/main/Token": undefined; - - "sap/ui/webc/main/Toolbar": undefined; - - "sap/ui/webc/main/ToolbarButton": undefined; - - "sap/ui/webc/main/ToolbarSelect": undefined; - - "sap/ui/webc/main/ToolbarSelectOption": undefined; - - "sap/ui/webc/main/ToolbarSeparator": undefined; - - "sap/ui/webc/main/ToolbarSpacer": undefined; - - "sap/ui/webc/main/Tree": undefined; - - "sap/ui/webc/main/TreeItem": undefined; - - "sap/ui/webc/main/TreeItemCustom": undefined; - } -} From 59441b1b1f7012520c08b4b9ac84ea2956ea7024 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 6 May 2026 13:28:32 -0700 Subject: [PATCH 2/5] Bump the github-actions group across 2 directories with 1 update (#74953) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/actions/setup-for-scripts/action.yml | 2 +- .github/workflows/CI.yml | 4 ++-- .github/workflows/pnpm-cache.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/actions/setup-for-scripts/action.yml b/.github/actions/setup-for-scripts/action.yml index 25fb611d71142e..63fd83f011b7e2 100644 --- a/.github/actions/setup-for-scripts/action.yml +++ b/.github/actions/setup-for-scripts/action.yml @@ -7,7 +7,7 @@ runs: - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 with: node-version: '24' - - uses: pnpm/action-setup@903f9c1a6ebcba6cf41d87230be49611ac97822e # v6.0.3 + - uses: pnpm/action-setup@8912a9102ac27614460f54aedde9e1e7f9aec20d # v6.0.5 with: run_install: | - args: [--filter, ., --filter, '{./scripts}...'] diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 5466d7231673dc..9a7d52a0289bf7 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -39,7 +39,7 @@ jobs: with: node-version: '24' - - uses: pnpm/action-setup@903f9c1a6ebcba6cf41d87230be49611ac97822e # v6.0.3 + - uses: pnpm/action-setup@8912a9102ac27614460f54aedde9e1e7f9aec20d # v6.0.5 - id: matrix run: | @@ -79,7 +79,7 @@ jobs: printf "Aborting: symlinks found:\n%s" "$symlinks"; exit 1 fi - - uses: pnpm/action-setup@903f9c1a6ebcba6cf41d87230be49611ac97822e # v6.0.3 + - uses: pnpm/action-setup@8912a9102ac27614460f54aedde9e1e7f9aec20d # v6.0.5 - name: Get pnpm cache info id: pnpm-cache diff --git a/.github/workflows/pnpm-cache.yml b/.github/workflows/pnpm-cache.yml index c2d50d164654d1..37a4896244cdef 100644 --- a/.github/workflows/pnpm-cache.yml +++ b/.github/workflows/pnpm-cache.yml @@ -15,7 +15,7 @@ jobs: - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 with: node-version: '24' - - uses: pnpm/action-setup@903f9c1a6ebcba6cf41d87230be49611ac97822e # v6.0.3 + - uses: pnpm/action-setup@8912a9102ac27614460f54aedde9e1e7f9aec20d # v6.0.5 - name: Get pnpm cache info id: pnpm-cache From 26c7aebe397801ca768497f240ac83b84dacdd3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hu=C3=A1ng=20J=C3=B9nli=C3=A0ng?= Date: Wed, 6 May 2026 16:47:15 -0400 Subject: [PATCH 3/5] =?UTF-8?q?=F0=9F=A4=96=20Merge=20PR=20#74915=20[estre?= =?UTF-8?q?e]=20Update=20key=20property=20type=20in=20Property=20interface?= =?UTF-8?q?=20by=20@JLHwung?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- types/estree/estree-tests.ts | 2 +- types/estree/index.d.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/types/estree/estree-tests.ts b/types/estree/estree-tests.ts index 8f41888cf697e8..2a5d890a2dc0b8 100644 --- a/types/estree/estree-tests.ts +++ b/types/estree/estree-tests.ts @@ -197,7 +197,7 @@ var propertyOrSpread: ESTree.Property | ESTree.SpreadElement = objectExpression. string = property.type; if (property.type === "Property") { - privateIdentifierOrExpression = property.key; + expression = property.key; expressionOrPattern = property.value; string = property.kind; } diff --git a/types/estree/index.d.ts b/types/estree/index.d.ts index 2bc66fb6c7107d..7d4ab36f42613e 100644 --- a/types/estree/index.d.ts +++ b/types/estree/index.d.ts @@ -316,7 +316,7 @@ export interface PrivateIdentifier extends BaseNode { export interface Property extends BaseNode { type: "Property"; - key: Expression | PrivateIdentifier; + key: Expression; value: Expression | Pattern; // Could be an AssignmentProperty kind: "init" | "get" | "set"; method: boolean; From 1102a6a827b2ab1cb4d2123745d92953dea43d7a Mon Sep 17 00:00:00 2001 From: Artem Kireev Date: Thu, 7 May 2026 00:25:18 +0300 Subject: [PATCH 4/5] =?UTF-8?q?=F0=9F=A4=96=20Merge=20PR=20#74828=20[steam?= =?UTF-8?q?community]=20Add=20asset=5Fproperties=20to=20CEconItem=20=20=20?= =?UTF-8?q?=20by=20@kjljxybr?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- types/steamcommunity/classes/CEconItem.d.ts | 9 +++++++++ types/steamcommunity/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/types/steamcommunity/classes/CEconItem.d.ts b/types/steamcommunity/classes/CEconItem.d.ts index 8f9ddca3d8ffe0..faae26a7c46d38 100644 --- a/types/steamcommunity/classes/CEconItem.d.ts +++ b/types/steamcommunity/classes/CEconItem.d.ts @@ -65,6 +65,15 @@ declare class CEconItem { tags: any[]; /** Not always present. An object containing arbitrary data as reported by the game's item server. */ app_data?: any; + /** An array of objects containing the item's asset properties. These are not always present, and their contents are entirely arbitrary and up to the game. */ asset_properties?: + Array< + & { propertyid: number; name?: string } + & ( + | { int_value: string; float_value?: never; string_value?: never } + | { float_value: string; int_value?: never; string_value?: never } + | { string_value: string; int_value?: never; float_value?: never } + ) + >; /** * Returns a URL where this item's image can be downloaded. diff --git a/types/steamcommunity/package.json b/types/steamcommunity/package.json index a1d2d54bfd8173..40e4999f89a883 100644 --- a/types/steamcommunity/package.json +++ b/types/steamcommunity/package.json @@ -1,7 +1,7 @@ { "private": true, "name": "@types/steamcommunity", - "version": "3.43.9999", + "version": "3.50.9999", "projects": [ "https://github.com/DoctorMcKay/node-steamcommunity" ], From c4881315e0e9e7fcbc53c80da1f2c3a17c75d1a8 Mon Sep 17 00:00:00 2001 From: Mosh-K <158998622+Mosh-K@users.noreply.github.com> Date: Thu, 7 May 2026 00:54:55 +0300 Subject: [PATCH 5/5] =?UTF-8?q?=F0=9F=A4=96=20Merge=20PR=20#74879=20[@type?= =?UTF-8?q?s/xrm]=20Fix=20ItemCollection.get()=20overload=20order=20to=20c?= =?UTF-8?q?orrectly=20return=20T=20|=20null=20by=20@Mosh-K?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- types/xrm/index.d.ts | 4 ++-- types/xrm/xrm-tests.ts | 23 ++++++++++++++++++++--- 2 files changed, 22 insertions(+), 5 deletions(-) diff --git a/types/xrm/index.d.ts b/types/xrm/index.d.ts index 413c63254a7923..215fe5b0cc4e3f 100644 --- a/types/xrm/index.d.ts +++ b/types/xrm/index.d.ts @@ -1862,14 +1862,14 @@ declare namespace Xrm { * @param itemNameOrNumber The item name or item number to get. * @returns The T matching the key itemName or the T in the itemNumber-th place. */ - get(itemNameOrNumber: string | number): TSubType; + get(itemNameOrNumber: string | number): T | null; /** * Gets the item given by key or index. * @param itemNameOrNumber The item name or item number to get. * @returns The T matching the key itemName or the T in the itemNumber-th place. */ - get(itemNameOrNumber: string | number): T | null; + get(itemNameOrNumber: string | number): TSubType; /** * Gets the item using a delegate matching function or the entire array of T if delegate is not provided. diff --git a/types/xrm/xrm-tests.ts b/types/xrm/xrm-tests.ts index fa24622dd98b90..e9344152b646db 100644 --- a/types/xrm/xrm-tests.ts +++ b/types/xrm/xrm-tests.ts @@ -630,13 +630,13 @@ function booleanAttributeControls(formContext: Xrm.FormContext) { // @ts-expect-error const notString: string = booleanAttribute.getValue(); - booleanAttribute = booleanAttribute.controls.get(0).getAttribute(); + booleanAttribute = booleanAttribute.controls.get(0).getAttribute(); booleanAttribute.controls.forEach((c: Xrm.Controls.BooleanControl) => c.setDisabled(true)); - booleanAttribute.controls.get(0).getAttribute().getAttributeType() === "boolean"; + booleanAttribute.controls.get(0).getAttribute().getAttributeType() === "boolean"; // @ts-expect-error - booleanAttribute.controls.get(0).getAttribute().getAttributeType() === "optionset"; + booleanAttribute.controls.get(0).getAttribute().getAttributeType() === "optionset"; } // Demonstrate add and remove methods for formContext.data.process @@ -799,3 +799,20 @@ const framedControlSetVisible = (formContext: Xrm.FormContext) => { // setVisible framedControl.setVisible(true); }; + +// Demonstrate ItemCollection.get() overloads +function testItemCollectionGet(formContext: Xrm.FormContext) { + // Without explicit type parameter: returns T | null + // $ExpectType Tab | null + formContext.ui.tabs.get(0); + + // $ExpectType Tab | null + formContext.ui.tabs.get("tabName"); + + // With explicit type parameter: returns TSubType (caller asserts item exists) + // $ExpectType Tab + formContext.ui.tabs.get(0); + + // $ExpectType Tab + formContext.ui.tabs.get("tabName"); +}