Icon Tab Bar - Sub tabs
This sample illustrates nested tabs with or without own content in their root-level tab.
Z2UI5_CL_SMPC_APP_382
Controls
sap.m
UI5 1.77
The facts
- Repository
- abap2UI5/samples-controls
- Class
Z2UI5_CL_SMPC_APP_382- Source file
z2ui5_cl_smpc_app_382.clas.abap↗- Library
- sap.m
- UI5 entity
sap.m.IconTabBar- Demo kit sample
sap.m.sample.IconTabBarSubTabs- SAP's own sample
- running at sdk.openui5.org ↗
- Minimum UI5
- 1.77
- In the playground
- runs in the browser, with no system and nothing installed
Keywords: icontabbar, icon, tab, bar, sap.m, icontabbarsubtabs, label, icontabfilter, text
Controls it builds
Read out of the builder chain by the abap2UI5 linter, not from the category this sample is filed under — which is what makes “which samples build one of these” a question the catalogue can answer at all.
Libraries
Run it here
The sample running, in this page — the app on its own, with no editor over it.
Switch to Playground with this code
Nothing is installed and nothing is sent anywhere: the ABAP is compiled to JavaScript in this browser and runs against abap2UI5 itself.
The ABAP
z2ui5_cl_smpc_app_382.clas.abap — 235 lines
Click a number to link to a line — shift-click for a range.
Read it on GitHub ↗
" @keywords icontabbar icon tab bar sap.m icontabbarsubtabs label icontabfilter text
" @summary This sample illustrates nested tabs with or without own content in their root-level tab.
CLASS z2ui5_cl_smpc_app_382 DEFINITION PUBLIC.
PUBLIC SECTION.
INTERFACES z2ui5_if_app.
PROTECTED SECTION.
DATA client TYPE REF TO z2ui5_if_client.
METHODS view_display.
PRIVATE SECTION.
ENDCLASS.
CLASS z2ui5_cl_smpc_app_382 IMPLEMENTATION.
METHOD z2ui5_if_app~main.
me->client = client.
IF client->check_on_navigated( ).
view_display( ).
ENDIF.
ENDMETHOD.
METHOD view_display.
DATA(view) = z2ui5_cl_ui5_view_builder=>factory( ).
view->ele( n = `View` ns = `mvc`
)->a( n = `xmlns:mvc` v = `sap.ui.core.mvc`
)->a( n = `xmlns` v = `sap.m`
)->tag( `Label`
)->a( n = `wrapping` v = `true`
)->a( n = `text`
v = `IconTabBar with filters with own content and sub tabs. The click area is split to allow the user to display the content or ` &&
`alternatively to expand/collapse the sub tabs.`
)->a( n = `class` v = `sapUiSmallMargin`
)->ele( `IconTabBar`
)->a( n = `class` v = `sapUiResponsiveContentPadding`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `key` v = `info`
)->a( n = `text` v = `Info`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info one`
)->tag( `Text`
)->a( n = `text` v = `Info one content goes here...`
)->tag( `Text`
)->a( n = `text` v = `Select another sub tab to see its content...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info two`
)->tag( `Text`
)->a( n = `text` v = `Info two content goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info three`
)->tag( `Text`
)->a( n = `text` v = `Info three content goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info four`
)->tag( `Text`
)->a( n = `text` v = `Info four content goes here...`
)->end(
)->end(
)->tag( `Text`
)->a( n = `text` v = `Info own content goes here...`
)->tag( `Text`
)->a( n = `text` v = `Select a sub tab to see its content...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `key` v = `attachments`
)->a( n = `text` v = `Attachments`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `text` v = `Attachment one`
)->tag( `Text`
)->a( n = `text` v = `Attachment one goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Attachment two`
)->tag( `Text`
)->a( n = `text` v = `Attachment two goes here...`
)->end(
)->end(
)->tag( `Text`
)->a( n = `text` v = `Attachments own content goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `key` v = `notes`
)->a( n = `text` v = `Notes`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `text` v = `Note one`
)->tag( `Text`
)->a( n = `text` v = `Note one goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Note two`
)->tag( `Text`
)->a( n = `text` v = `Note two goes here...`
)->end(
)->end(
)->tag( `Text`
)->a( n = `text` v = `Notes own content goes here...`
)->end(
)->end(
)->end(
)->tag( `Label`
)->a( n = `wrapping` v = `true`
)->a( n = `text` v = `IconTabBar with filters without own content - only sub tabs`
)->a( n = `class` v = `sapUiSmallMargin`
)->ele( `IconTabBar`
)->a( n = `class` v = `sapUiResponsiveContentPadding`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `key` v = `info`
)->a( n = `text` v = `Info`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info one`
)->tag( `Text`
)->a( n = `text` v = `Info one content goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info two`
)->tag( `Text`
)->a( n = `text` v = `Info two content goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info three`
)->tag( `Text`
)->a( n = `text` v = `Info three content goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Info four`
)->tag( `Text`
)->a( n = `text` v = `Info four content goes here...`
)->end(
)->end(
)->end(
)->ele( `IconTabFilter`
)->a( n = `key` v = `attachments`
)->a( n = `text` v = `Attachments`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `text` v = `Attachment one`
)->tag( `Text`
)->a( n = `text` v = `Attachment one goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Attachment two`
)->tag( `Text`
)->a( n = `text` v = `Attachment two goes here...`
)->end(
)->end(
)->end(
)->ele( `IconTabFilter`
)->a( n = `key` v = `notes`
)->a( n = `text` v = `Notes`
)->ele( `items`
)->ele( `IconTabFilter`
)->a( n = `text` v = `Note one`
)->tag( `Text`
)->a( n = `text` v = `Note one content goes here...`
)->end(
)->ele( `IconTabFilter`
)->a( n = `text` v = `Note two`
)->tag( `Text`
)->a( n = `text` v = `Note two content goes here...` ).
client->view_display( view->stringify( ) ).
ENDMETHOD.
ENDCLASS.
More in sap.m
- Standard List Item - Wrapping — This sample demonstrates the wrapping behavior of the title text and the description text…
- Icon Tab Bar - Filter — In this example, the Icon Tab Bar is used to apply filters on a table and display the cou…
- Icon Tab Bar - Text and Count — In this example, the Icon Tab Bar tabs display text and corresponding count.
- Icon Tab Bar - Inline Mode — In this example, the Icon Tab Bar tabs display the text and the count in one line.
- Icon Tab Bar - Icons Only — In this example, the Icon Tab Bar tabs display icons only.
- Icon Tab Bar - Text Only — In this example, the Icon Tab Bar tabs display text only.
- Icon Tab Bar - Separator — This is an example how to use separators in the Icon Tab Bar. You can choose an icon as a…
- ComboBox - Suggestions wrapping — Suggestions wrap automatically when longer then the dropdown width
- MultiComboBox - Suggestions wrapping — Suggestions wrap automatically when longer then the dropdown width
- MultiInput - Value States — This sample illustrates the different value states of the sap.m.MultiInput control.
- MultiInput - Suggestions wrapping — Suggestions wrap automatically when longer then the dropdown width
- Feed and News Tile — Shows Feed Tile and News Tile samples that can contain feed content, news content, and a…
On this page