namespace jQuery

Control sample: jQuery
Visiblity:
Available since: N/A
Module:
Application Component:

Nodes Overview

Node Description
jQuery.sap

Methods Overview

Method Description
jQuery.Event

Check the jQuery.Event class documentation available under "http://www.jquery.com" and "http://api.jquery.com/category/events/event-object/" for details.

jQuery.os

Holds information about the current operating system

jQuery.sap

Root Namespace for the jQuery plug-in provided by SAP SE.


Methods Overview

Method Description
addAriaDescribedBy

Adds the given ID reference to the aria-describedby attribute.

addAriaLabelledBy

Adds the given ID reference to the aria-labelledby attribute.

control

Extension function to the jQuery.fn which identifies SAPUI5 controls in the given jQuery context.

cursorPos

Sets or gets the position of the cursor in an element that supports cursor positioning.

disableSelection

Disable HTML elements selection.

enableSelection

Enable HTML elements to get selected.

firstFocusableDomRef

Returns the first focusable domRef in a given container (the first element of the collection)

getSelectedText

Retrieve the selected text in the first element of the collection.

Note: This feature is only supported for input element’s type of text, search, url, tel and password.

hasTabIndex

Returns true if the first element has a set tabindex.

lastFocusableDomRef

Returns the last focusable domRef in a given container

outerHTML

Returns the outer HTML of the given HTML element.

since: 1.58 use native <code>Element#outerHTML</code> instead
parentByAttribute

Gets the next parent DOM element with a given attribute and attribute value starting above the first given element

rect

Returns a rectangle describing the current visual positioning of the first DOM object in the collection (or null if no element was given).

rectContains

Returns whether a point described by X and Y is inside this Rectangle's boundaries.

removeAriaDescribedBy

Removes the given ID reference from the aria-describedby attribute.

removeAriaLabelledBy

Removes the given ID reference from the aria-labelledby attribute.

root
scrollLeftRTL

Sets or returns the scrollLeft value of the first element in the given jQuery collection in right-to-left mode. Precondition: The element is rendered in RTL mode.

Reason for this method is that the major browsers use three different values for the same scroll position when in RTL mode. This method hides those differences and returns/applies the same value that would be returned in LTR mode: The distance in px how far the given container is scrolled away from the leftmost scroll position.

Returns "undefined" if no element and no iPos is given.

scrollRightRTL

Returns the MIRRORED scrollLeft value of the first element in the given jQuery collection in right-to-left mode. Precondition: The element is rendered in RTL mode.

Reason for this method is that the major browsers return three different values for the same scroll position when in RTL mode. This method hides those differences and returns the value that would be returned in LTR mode if the UI would be mirrored horizontally: The distance in px how far the given container is scrolled away from the rightmost scroll position.

Returns "undefined" if no element is given.

selectText

Sets the text selection in the first element of the collection.

Note: This feature is only supported for input element’s type of text, search, url, tel and password.

uiarea

Returns a single UIArea if an index is provided or an array of UIAreas.

zIndex

Get (if no zIndex parameter is given) or set the z-index for an element.

addAriaDescribedBy

Adds the given ID reference to the aria-describedby attribute.

Param Type DefaultValue Description
sId string

The ID reference of an element

bPrepend boolean false

whether prepend or not

addAriaLabelledBy

Adds the given ID reference to the aria-labelledby attribute.

Param Type DefaultValue Description
sId string

The ID reference of an element

bPrepend boolean false

Whether prepend or not

control

Extension function to the jQuery.fn which identifies SAPUI5 controls in the given jQuery context.

Param Type DefaultValue Description
iIndex int

Optional parameter to return the control instance at the given index in the array.

bIncludeRelated boolean

Whether or not to respect the associated DOM elements to a control via data-sap-ui-related attribute.

cursorPos

Sets or gets the position of the cursor in an element that supports cursor positioning.

Param Type DefaultValue Description
iPos int

The cursor position to set (or no parameter to retrieve the cursor position)

disableSelection

Disable HTML elements selection.

Param Type DefaultValue Description

enableSelection

Enable HTML elements to get selected.

Param Type DefaultValue Description

firstFocusableDomRef

Returns the first focusable domRef in a given container (the first element of the collection)

Param Type DefaultValue Description

getSelectedText

Retrieve the selected text in the first element of the collection.

Note: This feature is only supported for input element’s type of text, search, url, tel and password.

Param Type DefaultValue Description

hasTabIndex

Returns true if the first element has a set tabindex.

Param Type DefaultValue Description

lastFocusableDomRef

Returns the last focusable domRef in a given container

Param Type DefaultValue Description

outerHTML

Returns the outer HTML of the given HTML element.

since: 1.58 use native <code>Element#outerHTML</code> instead
Param Type DefaultValue Description

parentByAttribute

Gets the next parent DOM element with a given attribute and attribute value starting above the first given element

Param Type DefaultValue Description
sAttribute string

Name of the attribute

sValue string

Value of the attribute (optional)

rect

Returns a rectangle describing the current visual positioning of the first DOM object in the collection (or null if no element was given).

Param Type DefaultValue Description

rectContains

Returns whether a point described by X and Y is inside this Rectangle's boundaries.

Param Type DefaultValue Description
iPosX int

The X coordinate

iPosY int

The Y coordinate

removeAriaDescribedBy

Removes the given ID reference from the aria-describedby attribute.

Param Type DefaultValue Description
sId string

The ID reference of an element

removeAriaLabelledBy

Removes the given ID reference from the aria-labelledby attribute.

Param Type DefaultValue Description
sId string

The ID reference of an element

root

Param Type DefaultValue Description
oRootControl object

The root control

scrollLeftRTL

Sets or returns the scrollLeft value of the first element in the given jQuery collection in right-to-left mode. Precondition: The element is rendered in RTL mode.

Reason for this method is that the major browsers use three different values for the same scroll position when in RTL mode. This method hides those differences and returns/applies the same value that would be returned in LTR mode: The distance in px how far the given container is scrolled away from the leftmost scroll position.

Returns "undefined" if no element and no iPos is given.

Param Type DefaultValue Description
iPos int

The desired scroll position

scrollRightRTL

Returns the MIRRORED scrollLeft value of the first element in the given jQuery collection in right-to-left mode. Precondition: The element is rendered in RTL mode.

Reason for this method is that the major browsers return three different values for the same scroll position when in RTL mode. This method hides those differences and returns the value that would be returned in LTR mode if the UI would be mirrored horizontally: The distance in px how far the given container is scrolled away from the rightmost scroll position.

Returns "undefined" if no element is given.

Param Type DefaultValue Description

selectText

Sets the text selection in the first element of the collection.

Note: This feature is only supported for input element’s type of text, search, url, tel and password.

Param Type DefaultValue Description
iStart int

Start position of the selection (inclusive)

iEnd int

End position of the selection (exclusive)

uiarea

Returns a single UIArea if an index is provided or an array of UIAreas.

Param Type DefaultValue Description
iIdx int

Index of the UIArea

zIndex

Get (if no zIndex parameter is given) or set the z-index for an element.

Param Type DefaultValue Description
zIndex int

The z-index to set