Difference between revisions of "Demo homepage"

From evidyaloka
Jump to: navigation, search
Line 5: Line 5:
  
 
<htmltag tagname="script" type="text/javascript">
 
<htmltag tagname="script" type="text/javascript">
<var dropDown = new OO.ui.DropdownWidget( {
+
var dropdownInput = new OO.ui.DropdownInputWidget( {
label: 'Dropdown menu: Select one option',
+
    options: [
// The menu is composed within the DropdownWidget
+
        { data: 'a', label: 'First' },
menu: {
+
        { data: 'b', label: 'Second', disabled: true },
items: [
+
        { optgroup: 'Group label' },
new OO.ui.MenuOptionWidget( {
+
        { data: 'c', label: 'First sub-item)' }
data: 'a',
+
    ]
label: 'First'
+
} );
} ),
+
$( document.body ).append( dropdownInput.$element );
new OO.ui.MenuOptionWidget( {
+
data: 'b',
+
label: 'Second (disabled option)',
+
disabled: true
+
} ),
+
new OO.ui.MenuOptionWidget( {
+
data: 'c',
+
label: 'Third'
+
} ),
+
new OO.ui.MenuOptionWidget( {
+
data: 'd',
+
label: 'The fourth option has a long label'
+
} ),
+
new OO.ui.MenuOptionWidget( {
+
data: 'e',
+
label: 'Fifth'
+
} )
+
]
+
}
+
} ),
+

Revision as of 04:02, 22 December 2022

Evidyaloka Welcomes you!!