Layout JAVASCRIPT UI Component API

Layout

Layout splits your content into resizable sections.

Selector

smart-layout

Properties

AanimationSets or gets the animation mode. Animation is disabled when the property is set to 'none'
CcontextMenuDataSourceDetermines the options that will be available for selection inside the context menu.
DdisabledEnables or disables the element.
DdataSourceSets or gets Layout's data source.
LlocaleSets or gets the language. Used in conjunction with the property messages.
MmessagesSets an object with string values, related to the different states of passwords strength.
OorientationSets or gets Layout's main orientation. The orientation is applied to all Splitters inside the Layout unless they have their orientation explicitly set in the dataSource.
RreadonlyIf the element is readonly, users cannot interact with it.
AallowLiveSplitDetermines whether splitting is live or not.
RrightToLeftSets or gets the value indicating whether the element is aligned to support locales using right-to-left fonts.
SselectedIndexDetermines the selected item.
TthemeDetermines the theme. Theme defines the look of the element
UunfocusableIf is set to true, the element cannot be focused.

Events

RresizeThis event is triggered after resizing is completed.
SstateChangeThis event is triggered when a change regarding the Layout's state has occured, such as inserting a new item, removing an item, etc.
CchangeThis event is triggered when the selection is changed.
CclosingThis event is triggered when a the context menu is about to be closed. The operation can be canceled by calling event.preventDefault() in the event handler function.
CcloseThis event is triggered when a the context menu is closed.
OopeningThis event is triggered when a the context menu is about to be opened. The operation can be canceled by calling event.preventDefault() in the event handler function.
OopenThis event is triggered when a the context menu is opened.
MmenuItemClickThis event is triggered when an option from the context menu has been clicked.

Methods

GgetItemReturns a Layout item according to the index that is passed.
RrefreshRefreshes the Layout
CcreateLayoutItemInserts a new item inside the Layout.
MmoveChildrenMoves all children from one item to another.

Properties

animation"none" | "simple" | "advanced"

Sets or gets the animation mode. Animation is disabled when the property is set to 'none'

Allowed Values

  • "none" - animation is disabled
  • "simple" - ripple animation is disabled
  • "advanced" - all animations are enabled

Default value

"advanced"

Example

Set the animation property.

 <smart-layout animation='none'></smart-layout>

Set the animation property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.animation = 'simple';

Get the animation property.

 const layout = document.querySelector('smart-layout');
 let animation = layout.animation;

contextMenuDataSourceany

Determines the options that will be available for selection inside the context menu.

Example

Set the contextMenuDataSource property.

 <smart-layout context-menu-data-source='["delete", "update"]'></smart-layout>

Set the contextMenuDataSource property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.contextMenuDataSource = [{ label: "delete", value: "delete" }, { label: "Update Item", value: "value" }];

Get the contextMenuDataSource property.

 const layout = document.querySelector('smart-layout');
 let contextMenuDataSource = layout.contextMenuDataSource;

disabledboolean

Enables or disables the element.

Default value

false

Example

Set the disabled property.

 <smart-layout disabled></smart-layout>

Set the disabled property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.disabled = false;

Get the disabled property.

 const layout = document.querySelector('smart-layout');
 let disabled = layout.disabled;

dataSourcearray

Sets or gets Layout's data source.

Example

Set the dataSource property.

 <smart-layout data-source='[object Object],[object Object]'></smart-layout>

Set the dataSource property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.dataSource = [object Object],[object Object],[object Object];

Get the dataSource property.

 const layout = document.querySelector('smart-layout');
 let dataSource = layout.dataSource;

localestring

Sets or gets the language. Used in conjunction with the property messages.

Default value

"en"

Example

Set the locale property.

 <smart-layout locale='de'></smart-layout>

Set the locale property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.locale = 'fr';

Get the locale property.

 const layout = document.querySelector('smart-layout');
 let locale = layout.locale;

messagesobject

Sets an object with string values, related to the different states of passwords strength.

Default value




"en": {

"propertyUnknownType": "'{{name}}' property is with undefined 'type' member!",

"propertyInvalidValue": "Invalid '{{name}}' property value! Actual value: {{actualValue}}, Expected value: {{value}}!",

"propertyInvalidValueType": "Invalid '{{name}}' property value type! Actual type: {{actualType}}, Expected type: {{type}}!",

"elementNotInDOM": "Element does not exist in DOM! Please, add the element to the DOM, before invoking a method.",

"moduleUndefined": "Module is undefined.",

"missingReference": "{{elementType}}: Missing reference to {{files}}.",

"invalidIndex": "{{elementType}}: '{{method}}' method accepts an index of type number.",

"invalidNode": "{{elementType}}: '{{method}}' method accepts an object or an array of objects as it's second parameter.",

"invalidSettings": "{{elementType}}: '{{method}}' method accepts a string or an object as it's second parameter.",

"delete": "Delete",

"noId": "{{elementType}}: requires an id in order to save/load a state."

}

Example

Set the messages property.

 <smart-layout messages='{"de":{"propertyUnknownType":"Die Eigenschaft '{{name}}' hat ein nicht definiertes 'type'-Member!","propertyInvalidValue":"Ungultiger Eigenschaftswert '{{name}}'! Aktueller Wert: {{actualValue}}, Erwarteter Wert: {{value}}!","propertyInvalidValueType":"Ungultiger Eigenschaftswert '{{name}}'! Aktueller Wert: {{actualType}}, Erwarteter Wert: {{type}}!","elementNotInDOM":"Element existiert nicht in DOM! Bitte fugen Sie das Element zum DOM hinzu, bevor Sie eine Methode aufrufen.","moduleUndefined":"Modul ist nicht definiert.","missingReference":"{{elementType}}: Fehlender Verweis auf {{files}}.","invalidIndex":"{{elementType}}: '{{method}}' Methode akzeptiert einen Index der Typennummer.","indexOutOfBound":"{{elementType}}: Nicht gebundener Index / Indizes in Methode '{{method}}'.","invalidNode":"{{elementType}}: '{{method}}' Die Methode akzeptiert ein Objekt oder ein Array von Objekten als zweiten Parameter.","invalidType":"{{elementType}}: '{{propertyName}}' muss vom Typ string oder Nummer sein.", "delete":"L�schen", "noId":"{{elementType}}: Ben�tigt eine ID, um einen Zustand zu speichern / laden."}}'></smart-layout>

Set the messages property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.messages = {"{"en":{"propertyUnknownType":"'{{name}}' property is with undefined 'type' member!","propertyInvalidValue":"Invalid '{{name}}' property value! Actual value: {{actualValue}}, Expected value: {{value}}!","propertyInvalidValueType":"Invalid '{{name}}' property value type! Actual type: {{actualType}}, Expected type: {{type}}!","elementNotInDOM":"Element does not exist in DOM! Please, add the element to the DOM, before invoking a method.","moduleUndefined":"Module is undefined.","missingReference":"{{elementType}}: Missing reference to {{files}}.","invalidIndex":"{{elementType}}: '{{method}}' method accepts an index of type number.","invalidNode":"{{elementType}}: '{{method}}' method accepts an object or an array of objects as it's second parameter.","invalidSettings":"{{elementType}}: '{{method}}' method accepts a string or an object as it's second parameter.", "delete":"Delete", "noId":"{{elementType}}: requires an id in order to save/load a state."}};

Get the messages property.

 const layout = document.querySelector('smart-layout');
 let messages = layout.messages;

orientation"horizontal" | "vertical"

Sets or gets Layout's main orientation. The orientation is applied to all Splitters inside the Layout unless they have their orientation explicitly set in the dataSource.

Allowed Values

  • "horizontal" - Horizontally oriented items.
  • "vertical" - Vertically oriented items.

Default value

"vertical"

Example

Set the orientation property.

 <smart-layout orientation='horizontal'></smart-layout>

Set the orientation property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.orientation = 'vertical';

Get the orientation property.

 const layout = document.querySelector('smart-layout');
 let orientation = layout.orientation;

readonlyboolean

If the element is readonly, users cannot interact with it.

Default value

false

Example

Set the readonly property.

 <smart-layout readonly></smart-layout>

Set the readonly property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.readonly = true;

Get the readonly property.

 const layout = document.querySelector('smart-layout');
 let readonly = layout.readonly;

allowLiveSplitboolean

Determines whether splitting is live or not.

Default value

false

Example

Set the allowLiveSplit property.

 <smart-layout allow-live-split></smart-layout>

Set the allowLiveSplit property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.allowLiveSplit = true;

Get the allowLiveSplit property.

 const layout = document.querySelector('smart-layout');
 let allowLiveSplit = layout.allowLiveSplit;

rightToLeftboolean

Sets or gets the value indicating whether the element is aligned to support locales using right-to-left fonts.

Default value

false

Example

Set the rightToLeft property.

 <smart-layout right-to-left></smart-layout>

Set the rightToLeft property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.rightToLeft = true;

Get the rightToLeft property.

 const layout = document.querySelector('smart-layout');
 let rightToLeft = layout.rightToLeft;

selectedIndexany

Determines the selected item.

Example

Set the selectedIndex property.

 <smart-layout selected-index='0'></smart-layout>

Set the selectedIndex property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.selectedIndex = 0.1;

Get the selectedIndex property.

 const layout = document.querySelector('smart-layout');
 let selectedIndex = layout.selectedIndex;

themestring

Determines the theme. Theme defines the look of the element

Default value

""

Example

Set the theme property.

 <smart-layout theme='blue'></smart-layout>

Set the theme property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.theme = 'red';

Get the theme property.

 const layout = document.querySelector('smart-layout');
 let theme = layout.theme;

unfocusableboolean

If is set to true, the element cannot be focused.

Default value

false

Example

Set the unfocusable property.

 <smart-layout unfocusable></smart-layout>

Set the unfocusable property by using the HTML Element's instance.

 const layout = document.querySelector('smart-layout');
 layout.unfocusable = false;

Get the unfocusable property.

 const layout = document.querySelector('smart-layout');
 let unfocusable = layout.unfocusable;

Events

resizeCustomEvent

This event is triggered after resizing is completed.

  • Bubbles Yes
  • Cancelable No
  • Interface CustomEvent
  • Event handler property onResize

Arguments

evCustomEvent

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of resize event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('resize', function (event) {
	// event handling code goes here.
})

stateChangeCustomEvent

This event is triggered when a change regarding the Layout's state has occured, such as inserting a new item, removing an item, etc.

  • Bubbles Yes
  • Cancelable No
  • Interface CustomEvent
  • Event handler property onStateChange

Arguments

evCustomEvent
ev.detailObject
ev.detail.item - The Splitter item that was the target of a change.
ev.detail.type - A description of the operation that has cause the change.

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of stateChange event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('stateChange', function (event) {
    const detail = event.detail,
        item = detail.item,
        type = detail.type;

	// event handling code goes here.
})

changeCustomEvent

This event is triggered when the selection is changed.

  • Bubbles Yes
  • Cancelable No
  • Interface CustomEvent
  • Event handler property onChange

Arguments

evCustomEvent
ev.detailObject
ev.detail.oldSelectedIndex - The Splitter item that was previously selected.
ev.detail.selectedIndex - The Splitter item that is currently selected.

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of change event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('change', function (event) {
    const detail = event.detail,
        oldSelectedIndex = detail.oldSelectedIndex,
        selectedIndex = detail.selectedIndex;

	// event handling code goes here.
})

closingCustomEvent

This event is triggered when a the context menu is about to be closed. The operation can be canceled by calling event.preventDefault() in the event handler function.

  • Bubbles Yes
  • Cancelable Yes
  • Interface CustomEvent
  • Event handler property onClosing

Arguments

evCustomEvent

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of closing event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('closing', function (event) {
	// event handling code goes here.
})

closeCustomEvent

This event is triggered when a the context menu is closed.

  • Bubbles Yes
  • Cancelable No
  • Interface CustomEvent
  • Event handler property onClose

Arguments

evCustomEvent

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of close event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('close', function (event) {
	// event handling code goes here.
})

openingCustomEvent

This event is triggered when a the context menu is about to be opened. The operation can be canceled by calling event.preventDefault() in the event handler function.

  • Bubbles Yes
  • Cancelable Yes
  • Interface CustomEvent
  • Event handler property onOpening

Arguments

evCustomEvent

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of opening event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('opening', function (event) {
	// event handling code goes here.
})

openCustomEvent

This event is triggered when a the context menu is opened.

  • Bubbles Yes
  • Cancelable No
  • Interface CustomEvent
  • Event handler property onOpen

Arguments

evCustomEvent

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of open event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('open', function (event) {
	// event handling code goes here.
})

menuItemClickCustomEvent

This event is triggered when an option from the context menu has been clicked.

  • Bubbles Yes
  • Cancelable No
  • Interface CustomEvent
  • Event handler property onMenuItemClick

Arguments

evCustomEvent
ev.detailObject
ev.detail.target - The Splitter item that was the target of the context menu opening.
ev.detail.item - The Context menu item that was clicked.
ev.detail.label - The label of the context menu that was clicked.
ev.detail.value - The value of the context menu that was clicked.

Methods

isDefaultPrevented

Returns true if the event was prevented by any of its subscribers.

Returns

boolean true if the default action was prevented. Otherwise, returns false.

preventDefault

The preventDefault() method prevents the default action for a specified event. In this way, the source component suppresses the built-in behavior that follows the event.

stopPropagation

The stopPropagation() method of the Event interface prevents further propagation of the current event in the capturing and bubbling phases.

Example

Set up the event handler of menuItemClick event.

const layout = document.querySelector('smart-layout');
layout.addEventListener('menuItemClick', function (event) {
    const detail = event.detail,
        target = detail.target,
        item = detail.item,
        label = detail.label,
        value = detail.value;

	// event handling code goes here.
})

Methods

getItem( index: number | string): void

Returns a Layout item according to the index that is passed.

Arguments

indexnumber | string

The index of an item.


Invoke the getItem method.

const layout = document.querySelector('smart-layout');
layout.getItem(1);

refresh(): void

Refreshes the Layout


Invoke the refresh method.

const layout = document.querySelector('smart-layout');
layout.refresh();

createLayoutItem( type: any, position?: string | undefined): void

Inserts a new item inside the Layout.

Arguments

typeany

The index of an item to be removed or an instance of Smart.SplitterItem.

position?string | undefined

A string that represents the position where the new item will be created.


Invoke the createLayoutItem method.

const layout = document.querySelector('smart-layout');
layout.createLayoutItem("newItem, 'top'","newItem, 'bottom'");

moveChildren( oldItem: any, newItem: any): void

Moves all children from one item to another.

Arguments

oldItemany

The source item that will have it's content removed.

newItemany

The host item that will have it's content replaced.


Invoke the moveChildren method.

const layout = document.querySelector('smart-layout');
layout.moveChildren("oldItem, newItem");

LayoutGroup

LayoutGroup represents a group of layout items inside the Layout.

Selector

smart-layout-group

Properties

DdisabledEnables or disables the element.
MmodifiersSets or gets the modifiers of the Layout item. Click for more details. Property object's options:
    MminDetermines the min size of the item.
    LlabelDetermines the label of the item.
    OorientationDetermines the group orientation.
    SsizeDetermines the size of the item.
    UunfocusableIf is set to true, the element cannot be focused.

    Properties

    disabledboolean

    Enables or disables the element.

    Default value

    false

    Example

    Set the disabled property.

     <smart-layout-group disabled></smart-layout-group>

    Set the disabled property by using the HTML Element's instance.

     const layoutgroup = document.querySelector('smart-layout-group');
     layoutgroup.disabled = false;

    Get the disabled property.

     const layoutgroup = document.querySelector('smart-layout-group');
     let disabled = layoutgroup.disabled;

    modifiersarray

    Sets or gets the modifiers of the Layout item.

    Example

    Set the modifiers property.

     <smart-layout-group modifiers='[ "resize", "drag"]'></smart-layout-group>

    Set the modifiers property by using the HTML Element's instance.

     const layoutgroup = document.querySelector('smart-layout-group');
     layoutgroup.modifiers = [ "close", "drag"];

    Get the modifiers property.

     const layoutgroup = document.querySelector('smart-layout-group');
     let modifiers = layoutgroup.modifiers;

    minnumber

    Determines the min size of the item.

    Default value

    50

    Example

    Set the min property.

     <smart-layout-group min='10'></smart-layout-group>

    Set the min property by using the HTML Element's instance.

     const layoutgroup = document.querySelector('smart-layout-group');
     layoutgroup.min = 20;

    Get the min property.

     const layoutgroup = document.querySelector('smart-layout-group');
     let min = layoutgroup.min;

    labelstring

    Determines the label of the item.

    Default value

    "Group"

    Example

    Set the label property.

     <smart-layout-group label='No Content'></smart-layout-group>

    Set the label property by using the HTML Element's instance.

     const layoutgroup = document.querySelector('smart-layout-group');
     layoutgroup.label = 'Please Add Content...';

    Get the label property.

     const layoutgroup = document.querySelector('smart-layout-group');
     let label = layoutgroup.label;

    orientation"horizontal" | "vertical"

    Determines the group orientation.

    Allowed Values

    • "horizontal" - Horizontally oriented group items.
    • "vertical" - Vertically oriented group items.

    Default value

    "vertical"

    Example

    Set the orientation property.

     <smart-layout-group orientation='horizontal'></smart-layout-group>

    Set the orientation property by using the HTML Element's instance.

     const layoutgroup = document.querySelector('smart-layout-group');
     layoutgroup.orientation = 'vertical';

    Get the orientation property.

     const layoutgroup = document.querySelector('smart-layout-group');
     let orientation = layoutgroup.orientation;

    sizeany

    Determines the size of the item.

    Example

    Set the size property.

     <smart-layout-group size='100'></smart-layout-group>

    Set the size property by using the HTML Element's instance.

     const layoutgroup = document.querySelector('smart-layout-group');
     layoutgroup.size = 300;

    Get the size property.

     const layoutgroup = document.querySelector('smart-layout-group');
     let size = layoutgroup.size;

    unfocusableboolean

    If is set to true, the element cannot be focused.

    Default value

    false

    Example

    Set the unfocusable property.

     <smart-layout-group unfocusable></smart-layout-group>

    Set the unfocusable property by using the HTML Element's instance.

     const layoutgroup = document.querySelector('smart-layout-group');
     layoutgroup.unfocusable = false;

    Get the unfocusable property.

     const layoutgroup = document.querySelector('smart-layout-group');
     let unfocusable = layoutgroup.unfocusable;

    Methods


    LayoutItem

    Layout item represents a single content section inside the Layout.

    Selector

    smart-layout-item

    Properties

    DdisabledEnables or disables the element.
    MmodifiersSets or gets the modifiers of the Layout item. Click for more details. Property object's options:
      MminDetermines the min size of the item.
      LlabelDetermines the label of the item.
      SsizeDetermines the size of the item.
      UunfocusableIf is set to true, the element cannot be focused.

      Properties

      disabledboolean

      Enables or disables the element.

      Default value

      false

      Example

      Set the disabled property.

       <smart-layout-item disabled></smart-layout-item>

      Set the disabled property by using the HTML Element's instance.

       const layoutitem = document.querySelector('smart-layout-item');
       layoutitem.disabled = false;

      Get the disabled property.

       const layoutitem = document.querySelector('smart-layout-item');
       let disabled = layoutitem.disabled;

      modifiersarray

      Sets or gets the modifiers of the Layout item.

      Example

      Set the modifiers property.

       <smart-layout-item modifiers='[ "resize", "drag"]'></smart-layout-item>

      Set the modifiers property by using the HTML Element's instance.

       const layoutitem = document.querySelector('smart-layout-item');
       layoutitem.modifiers = [ "close", "drag"];

      Get the modifiers property.

       const layoutitem = document.querySelector('smart-layout-item');
       let modifiers = layoutitem.modifiers;

      minnumber

      Determines the min size of the item.

      Default value

      50

      Example

      Set the min property.

       <smart-layout-item min='10'></smart-layout-item>

      Set the min property by using the HTML Element's instance.

       const layoutitem = document.querySelector('smart-layout-item');
       layoutitem.min = 20;

      Get the min property.

       const layoutitem = document.querySelector('smart-layout-item');
       let min = layoutitem.min;

      labelstring

      Determines the label of the item.

      Default value

      "Item"

      Example

      Set the label property.

       <smart-layout-item label='No Content'></smart-layout-item>

      Set the label property by using the HTML Element's instance.

       const layoutitem = document.querySelector('smart-layout-item');
       layoutitem.label = 'Please Add Content...';

      Get the label property.

       const layoutitem = document.querySelector('smart-layout-item');
       let label = layoutitem.label;

      sizeany

      Determines the size of the item.

      Example

      Set the size property.

       <smart-layout-item size='100'></smart-layout-item>

      Set the size property by using the HTML Element's instance.

       const layoutitem = document.querySelector('smart-layout-item');
       layoutitem.size = 300;

      Get the size property.

       const layoutitem = document.querySelector('smart-layout-item');
       let size = layoutitem.size;

      unfocusableboolean

      If is set to true, the element cannot be focused.

      Default value

      false

      Example

      Set the unfocusable property.

       <smart-layout-item unfocusable></smart-layout-item>

      Set the unfocusable property by using the HTML Element's instance.

       const layoutitem = document.querySelector('smart-layout-item');
       layoutitem.unfocusable = false;

      Get the unfocusable property.

       const layoutitem = document.querySelector('smart-layout-item');
       let unfocusable = layoutitem.unfocusable;

      Methods


      TabLayoutGroup

      TabLayoutGroup represents a group of TabLayoutItems each with it's own Tab label.

      Selector

      smart-tab-layout-group

      Properties

      DdisabledEnables or disables the element.
      MmodifiersSets or gets the modifiers of the Layout item. Click for more details. Property object's options:
        MminDetermines the min size of the item.
        LlabelDetermines the label of the item.
        OorientationDetermines the group orientation.
        PpositionDetermines the position of the tab items group.
        SsizeDetermines the size of the item.
        UunfocusableIf is set to true, the element cannot be focused.

        Properties

        disabledboolean

        Enables or disables the element.

        Default value

        false

        Example

        Set the disabled property.

         <smart-tab-layout-group disabled></smart-tab-layout-group>

        Set the disabled property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.disabled = false;

        Get the disabled property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let disabled = tablayoutgroup.disabled;

        modifiersarray

        Sets or gets the modifiers of the Layout item.

        Example

        Set the modifiers property.

         <smart-tab-layout-group modifiers='[ "resize", "drag"]'></smart-tab-layout-group>

        Set the modifiers property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.modifiers = [ "close", "drag"];

        Get the modifiers property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let modifiers = tablayoutgroup.modifiers;

        minnumber

        Determines the min size of the item.

        Default value

        50

        Example

        Set the min property.

         <smart-tab-layout-group min='10'></smart-tab-layout-group>

        Set the min property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.min = 20;

        Get the min property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let min = tablayoutgroup.min;

        labelstring

        Determines the label of the item.

        Default value

        "TabGroup"

        Example

        Set the label property.

         <smart-tab-layout-group label='No Content'></smart-tab-layout-group>

        Set the label property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.label = 'Please Add Content...';

        Get the label property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let label = tablayoutgroup.label;

        orientation"horizontal" | "vertical"

        Determines the group orientation.

        Allowed Values

        • "horizontal" - Horizontally oriented group items.
        • "vertical" - Vertically oriented group items.

        Default value

        "vertical"

        Example

        Set the orientation property.

         <smart-tab-layout-group orientation='horizontal'></smart-tab-layout-group>

        Set the orientation property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.orientation = 'vertical';

        Get the orientation property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let orientation = tablayoutgroup.orientation;

        position"top" | "bottom" | "left" | "right"

        Determines the position of the tab items group.

        Allowed Values

        • "top" - Positions the tab labels on the top side of the group.
        • "bottom" - Positions the tab labels on the bottom side of the group.
        • "left" - Positions the tab labels on the left side of the group.
        • "right" - Positions the tab labels on the right side of the group.

        Default value

        "top"

        Example

        Set the position property.

         <smart-tab-layout-group position='bottom'></smart-tab-layout-group>

        Set the position property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.position = 'top';

        Get the position property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let position = tablayoutgroup.position;

        sizeany

        Determines the size of the item.

        Example

        Set the size property.

         <smart-tab-layout-group size='100'></smart-tab-layout-group>

        Set the size property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.size = 300;

        Get the size property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let size = tablayoutgroup.size;

        unfocusableboolean

        If is set to true, the element cannot be focused.

        Default value

        false

        Example

        Set the unfocusable property.

         <smart-tab-layout-group unfocusable></smart-tab-layout-group>

        Set the unfocusable property by using the HTML Element's instance.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         tablayoutgroup.unfocusable = false;

        Get the unfocusable property.

         const tablayoutgroup = document.querySelector('smart-tab-layout-group');
         let unfocusable = tablayoutgroup.unfocusable;

        Methods


        TabLayoutItem

        TabLayoutItem represents a Layout Item that has a Tab label and is applicable to a TabLayoutGroup.

        Selector

        smart-tab-layout-item

        Properties

        DdisabledEnables or disables the element.
        MmodifiersSets or gets the modifiers of the Layout item. Click for more details. Property object's options:
          MminDetermines the min size of the item.
          LlabelDetermines the label of the item.
          OorientationDetermines the group orientation.
          SsizeDetermines the size of the item.
          UunfocusableIf is set to true, the element cannot be focused.

          Properties

          disabledboolean

          Enables or disables the element.

          Default value

          false

          Example

          Set the disabled property.

           <smart-tab-layout-item disabled></smart-tab-layout-item>

          Set the disabled property by using the HTML Element's instance.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           tablayoutitem.disabled = false;

          Get the disabled property.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           let disabled = tablayoutitem.disabled;

          modifiersarray

          Sets or gets the modifiers of the Layout item.

          Example

          Set the modifiers property.

           <smart-tab-layout-item modifiers='[ "resize", "drag"]'></smart-tab-layout-item>

          Set the modifiers property by using the HTML Element's instance.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           tablayoutitem.modifiers = [ "close", "drag"];

          Get the modifiers property.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           let modifiers = tablayoutitem.modifiers;

          minnumber

          Determines the min size of the item.

          Default value

          50

          Example

          Set the min property.

           <smart-tab-layout-item min='10'></smart-tab-layout-item>

          Set the min property by using the HTML Element's instance.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           tablayoutitem.min = 20;

          Get the min property.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           let min = tablayoutitem.min;

          labelstring

          Determines the label of the item.

          Default value

          "TabItem"

          Example

          Set the label property.

           <smart-tab-layout-item label='No Content'></smart-tab-layout-item>

          Set the label property by using the HTML Element's instance.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           tablayoutitem.label = 'Please Add Content...';

          Get the label property.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           let label = tablayoutitem.label;

          orientation"horizontal" | "vertical"

          Determines the group orientation.

          Allowed Values

          • "horizontal" - Horizontally oriented group items.
          • "vertical" - Vertically oriented group items.

          Default value

          "vertical"

          Example

          Set the orientation property.

           <smart-tab-layout-item orientation='horizontal'></smart-tab-layout-item>

          Set the orientation property by using the HTML Element's instance.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           tablayoutitem.orientation = 'vertical';

          Get the orientation property.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           let orientation = tablayoutitem.orientation;

          sizeany

          Determines the size of the item.

          Example

          Set the size property.

           <smart-tab-layout-item size='100'></smart-tab-layout-item>

          Set the size property by using the HTML Element's instance.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           tablayoutitem.size = 300;

          Get the size property.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           let size = tablayoutitem.size;

          unfocusableboolean

          If is set to true, the element cannot be focused.

          Default value

          false

          Example

          Set the unfocusable property.

           <smart-tab-layout-item unfocusable></smart-tab-layout-item>

          Set the unfocusable property by using the HTML Element's instance.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           tablayoutitem.unfocusable = false;

          Get the unfocusable property.

           const tablayoutitem = document.querySelector('smart-tab-layout-item');
           let unfocusable = tablayoutitem.unfocusable;

          Methods