Sets the initial group of depth. If at least one default group does not exist on the specific depth, you have to set the proper initial group to that depth. If not, you have to change the group using the focus controller API at an appropriate time.
(static) setInitialGroupOfDepth(depth, groupopt) → {caph.focus.focusControllerProvider}
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
depth |
number | string | Object | The number indicates the depth to set initial group to. If the string is passed, depth is used as 0. If an object is passed, property name will be depth and property value will be group. |
|
group |
string |
<optional> |
A string to be initial group. |
Returns:
Example
angular.module('myApp', ['caph.focus']).config(['focusControllerProvider', function(focusControllerProvider) {
focusControllerProvider.setInitialGroupOfDepth('group1');
focusControllerProvider.setInitialGroupOfDepth(1, 'group2');
focusControllerProvider.setInitialGroupOfDepth({
2: 'group3',
3: 'group4'
});
}]);