new Toggler(options)
A class for enabling toggling
Parameters:
Name | Type | Description | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object |
Properties
|
- Source:
Methods
reveal(id, $container, page) → {boolean}
Reveals an element and its parent section as identified by it's id
Parameters:
Name | Type | Description |
---|---|---|
id |
string | An element ID within the $container |
$container |
Object | jQuery element to search in |
page |
Page |
- Source:
Returns:
Target ID was found
- Type
- boolean
toggle($heading, page)
Given a heading, toggle it and any of its children
Parameters:
Name | Type | Description |
---|---|---|
$heading |
jQuery.Object | A heading belonging to a section |
page |
Page |
- Source: