Skip to main content
Version: 1.x

Interface: UI5NavigationAPI

Ai

UI5 Navigation API provided by the ui5Navigation fixture.

Ai Context​

Use to navigate between SAP Fiori Launchpad apps and views.

Remarks​

Wraps all 11 FLP navigation module functions. The page argument is injected automatically from the Playwright fixture system.

Example​

test('navigate to app', async ({ ui5Navigation }) => {
await ui5Navigation.navigateToApp('PurchaseOrder-manage');
const hash = await ui5Navigation.getCurrentHash();
});

Methods​

getCurrentHash()​

getCurrentHash(): Promise<string>

Ai

Returns the current URL hash (without leading '#').

Returns​

Promise<string>

The current hash string.

Ai Context​

Use to read the current navigation hash for assertions.

Example​

const hash = await ui5Navigation.getCurrentHash();

navigateBack(options?): Promise<void>

Ai

Navigates back in browser history.

Parameters​

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to go back to the previous page in history.

Example​

await ui5Navigation.navigateBack();

navigateForward(options?): Promise<void>

Ai

Navigates forward in browser history.

Parameters​

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to go forward to the next page in history.

Example​

await ui5Navigation.navigateForward();

navigateToApp(appId, options?): Promise<void>

Ai

Navigates to a SAP app by semantic object hash.

Parameters​

appId​

string

Semantic object hash (e.g., 'PurchaseOrder-manage').

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to open a Fiori app by its semantic object hash.

Example​

await ui5Navigation.navigateToApp('PurchaseOrder-manage');

navigateToHash(hash, options?): Promise<void>

Ai

Navigates to a specific hash directly.

Parameters​

hash​

string

The hash to navigate to (without leading '#').

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to navigate directly to a URL hash fragment.

Example​

await ui5Navigation.navigateToHash('Shell-home');

navigateToHome(options?): Promise<void>

Ai

Navigates to the FLP home screen.

Parameters​

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to return to the Fiori Launchpad home page.

Example​

await ui5Navigation.navigateToHome();

navigateToIntent(intent, params?, options?): Promise<void>

Ai

Navigates to an SAP intent with optional parameters.

Parameters​

intent​

NavigationIntent

Semantic object and action descriptor.

params?​

Readonly<Record<string, string>>

Optional query parameters for the intent.

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to navigate via semantic object + action with params.

Example​

await ui5Navigation.navigateToIntent(
{ semanticObject: 'PurchaseOrder', action: 'manage' },
{ CompanyCode: '1000' },
);

navigateToSectionLink(linkName, options?): Promise<void>

Ai

Navigates via an FLP Section Link in a Space-based layout.

Parameters​

linkName​

string

Accessible name (visible text) of the section link.

options?​

SectionLinkNavigationOptions

Section link navigation options (timeout).

Returns​

Promise<void>

Remarks​

Uses Playwright-native getByRole('link') to locate the section link.

Ai Context​

Use to navigate within FLP Space sections.

Example​

await ui5Navigation.navigateToSectionLink('Purchase Orders');

navigateToSpace(spaceTitle, options?): Promise<void>

Ai

Navigates to an FLP Space Tab by its visible title text.

Parameters​

spaceTitle​

string

Visible title text of the FLP Space Tab.

options?​

SpaceNavigationOptions

Space navigation options (timeout, exact).

Returns​

Promise<void>

Remarks​

Uses Playwright-native getByText() because sap.m.IconTabFilter has no press() / firePress() methods.

Ai Context​

Use to switch between FLP Spaces in modern BTP Work Zone layouts.

Example​

await ui5Navigation.navigateToSpace('Procurement');

navigateToTile(title, options?): Promise<void>

Ai

Navigates to an FLP tile by its title text.

Parameters​

title​

string

Title text of the FLP tile.

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to click a Fiori Launchpad tile by its visible title.

Example​

await ui5Navigation.navigateToTile('Purchase Orders');

searchAndOpenApp()​

searchAndOpenApp(title, options?): Promise<void>

Ai

Searches for an app in the FLP shell search bar and opens it.

Parameters​

title​

string

Title of the app to search for.

options?​

NavigationOptions

Navigation options.

Returns​

Promise<void>

Ai Context​

Use to find and launch a Fiori app via shell search.

Example​

await ui5Navigation.searchAndOpenApp('Purchase Orders');