Salla Docs
Merchant API
  • Merchant API
  • Salla OAuth 2.0
Partner APIs
  • App API
  • Shipment API
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Change Log
Salla CLI
Merchant API
  • Merchant API
  • Salla OAuth 2.0
Partner APIs
  • App API
  • Shipment API
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Change Log
Salla CLI
Salla - Opensource
Salla - Developers Community
  1. Elements
  • Overview
  • Usage
  • Components Customization
  • Elements
    • Apps Icons
    • Breadcrumb
    • Color Picker
    • Conditional Fields
    • Count Down
    • Filters
    • Infinite Scroll
    • List Tile
    • Loading
    • Map
    • Modal
    • Placeholder
    • Progress Bar
    • Rating Stars
    • Reviews
    • Reviews Summary
    • Sheet
    • Skeleton
    • Slider
    • Social
    • Social Share
    • Tabs
  • Form
    • Button
    • Bottom Alert
    • Contacts
    • Date Time Picker
    • File Upload
    • Menu
    • Quantity Input
    • Select
    • Tel Input
  • Product
    • Add Product
    • Advertisement
    • Comments
    • Conditional Offer
    • Gifting
    • Installment
    • Meta Data
    • Offer
    • Offer Modal
    • Orders
    • Payments
    • Product Availability
    • Product Card
    • Products List
    • Product Options
    • Product Size Guide
    • Products Slider
    • Quick Buy
    • Quick Order
    • Scopes
    • Search
  • User
    • Cart Summary
    • Localization
    • Login
    • Loyalty
    • Rating
    • User Menu
    • User Profile
    • User Settings
    • Verify
  1. Elements

Tabs

The <salla-tabs> web component makes it possible to have several panes inside a single view. This implies the content is presented in several independent panes, each of which can be seen independently of the others. If the user wants to see a certain section of the page, they click on that tab's header. The component groups several tabs/panes that each consists of <salla-tabs-header> and <salla-tabs-content> where:
Salla Tabs Header: The <salla-tabs-header> web sub-component represents the tab for a specific tab/pane within the <salla-tabs> web component, allowing users to select and navigate to a particular section of the page.
Salla Tabs Content: The <salla-tabs-content> web sub-component represents the content or tab/pane associated with a specific header within the <salla-tabs> web component, displaying the relevant information or functionality when the corresponding tab is selected.

Example#

Tabs

Usage#

HTML
SASS

Properties#

salla-tabs#

PropertyAttributeDescriptionTypeDefault
Background Colorbackground-colorBackground color valuestringundefined
VerticalverticalAligns tabs vertically.booleanfalse

salla-tab-header#

PropertyAttributeDescriptionTypeDefault
NamenameHeader identifier name to sync with the content.stringundefined
Active Classactive-classThe class applied to the currently active(selected) tabstringundefined
HeightheightSet the height of the tab barstring or numberundefined
CenteredcenteredCenter tab items in the given flex.booleanfalse

salla-tab-content#

PropertyAttributeDescriptionTypeDefault
NamenameSet name of the tab content. Mainly used as a key to synchronize the content with it's respective header.stringundefined

Methods#

The pre-defined methods allow for calling functions built by Salla to carry out certain actvities, such as getChild which exposes self for the parent.

salla-tab-header#

MethodDescriptionReturn
"getChild"Expose self for the parent.Promise<{selected: `boolean`, unselect: `boolean`, name: `string`, id: `string` }>

salla-tab-content#

MethodDescriptionReturn
"getChild"Expose self for the parent.Promise<{selected: `boolean`, unselect: `boolean`, name: `string`, id: `string` }>

Events#

salla-tab-header#

EventDescription
"tabSelected"Emits event object when clicked or selected.

Slots#

salla-tabs#

SlotDescription
contentThe current and active tab content section. The salla-tab-content component is used here.
headerThe tab header section. The salla-tab-header component is used here.
Modified at 2024-08-18 10:53:21
Previous
Social Share
Next
Form