1.12.5 • Published 5 years ago

sling-web-component-select v1.12.5

Weekly downloads
160
License
-
Repository
-
Last release
5 years ago

sling-web-component-select

Install

npm install sling-web-component-select

Tag

  <sling-select></sling-select>

Dependencies

  • sling-framework
  • sling-helpers

    Attributes and properties

       
NameTypeDefault ValuesReflectToAttributeObservercallSdk
disabledBooleanFalse:heavy_check_mark:
nameString:heavy_check_mark:
srcoptionsArray
sizeNumber:heavy_check_mark:
valueString:heavy_check_mark:

Description

NameDescription
disabledDisables the Select options, preventing the user from clicking and changing their style to dimmed.
nameNames the select tag to control.
srcoptionsArray of objects formed by the following properties: name that indicates the text that will be shown in the option and id that will be the value of the option and will be passed through an event to the form that uses the element. The tag will receive this array to mount the select options.
sizeIf the control is presented as a scroll listbox, this attribute represents the number of rows in the list box that should be visible at a given time. More info in Select MDN Docs.
valueValue of the selected tag in the current moment.

Events

  • change

Description: The event is triggered when a change of the value of select, taking in the detail of the event the value of the selected option.

Examples

srcoptions Array

const srcoptions = 
[
    {
      name: 'Option1',
      id: 1,
    },
    {
      name: 'Option2',
      id: 2,
    },
    {
      name: 'Option3',
      id: 3,
    }
]

All component examples can be emulated using the npm start sling-web-component-select command.

Use

<sling-select></sling-select>

image

<sling-select disabled></sling-select>

image

1.12.5

5 years ago

1.12.4

5 years ago

1.12.3

5 years ago

1.12.2

5 years ago

1.12.0

5 years ago

1.11.7

5 years ago

1.11.6

5 years ago

1.11.5

6 years ago

1.11.4

6 years ago

1.11.3

6 years ago

1.11.2

6 years ago

1.11.1

6 years ago

1.11.0

6 years ago

1.8.0

6 years ago

1.7.0

6 years ago

1.6.0

6 years ago

1.5.0

6 years ago

1.4.0

6 years ago

1.3.0

6 years ago

0.17.0

6 years ago

0.16.0

6 years ago

0.15.1

6 years ago

0.15.0

6 years ago

0.14.1

6 years ago

0.14.0

6 years ago

0.13.2

6 years ago

0.13.1

6 years ago

0.13.0

6 years ago

0.12.0

6 years ago

0.11.0

6 years ago

0.10.1

6 years ago

0.10.0

6 years ago

0.9.0

6 years ago

0.8.0

6 years ago

0.7.1

6 years ago

0.7.0

6 years ago

0.5.0

6 years ago

0.4.0

6 years ago

0.3.3

6 years ago