import { experimentOn } from '@islavi/ng2-component-lab';
import { IDropDownOption, DropDownOptionType, DropDownTypes } from "../../src/angular/form-elements/dropdown/dropdown-models";
const options1: IDropDownOption[] = [
{
label: 'First Option Label',
value: 'firstOptionValue',
},
{
label: 'Second Option Label',
value: 'secondOptionValue',
},
{
label: 'Third Option Label',
value: 'thirdOptionValue',
type: DropDownOptionType.Simple
}
];
const options2: IDropDownOption[] = [
{
label: 'Header Label',
value: 'headerValue',
type: DropDownOptionType.Header
},
{
label: 'First Option Label',
value: 'firstOptionValue',
type: DropDownOptionType.Simple
},
{
label: 'Disabled Option Label',
value: 'headerValue',
type: DropDownOptionType.Disable
},
{
label: 'Second Option Label',
value: 'secondOptionValue',
type: DropDownOptionType.Simple
},
{
label: 'Ruler Label',
value: 'rulerValue',
type: DropDownOptionType.HorizontalLine
},
{
label: 'Third Option Label',
value: 'thirdOptionValue',
type: DropDownOptionType.Simple
},
{
label: 'Fourth Option Label',
value: 'FourthOptionValue',
type: DropDownOptionType.Simple
},
{
label: 'Fifth Option Label',
value: 'fifthOptionValue',
type: DropDownOptionType.Simple
},
{
label: 'Ruler Label',
value: 'rulerValue',
type: DropDownOptionType.HorizontalLine
},
{
label: 'Third Option Label',
value: 'thirdOptionValue',
type: DropDownOptionType.Simple
},
{
label: 'Fourth Option Label',
value: 'FourthOptionValue',
type: DropDownOptionType.Simple
},
{
label: 'Fifth Option Label',
value: 'fifthOptionValue',
type: DropDownOptionType.Simple
}
];
export default experimentOn('DropDown')
.group("DropDown", [
{
id: 'normalDropDown',
showSource: true,
context: {
options: options1,
onChange: function(option) {
this.valueSelected = option.value;
}
},
title: 'Normal DropDown',
description: 'Normal DropDown',
template: `