Classes
Methods
-
<static> clickElement( base, selectorArray [, matchSelf ] ) → {boolean}
-
Description
Run querySelector to get an element, then click it.
Parameters
Name Type Attributes Default Description baseexternal:Element Where to start looking.
selectorArrayArray.<string> CSS selectors to use to find an element.
matchSelfboolean <optional> false If a CSS selector would match base, then use it.
Returns
Details
-
<static> focusOnElement( element [, removeNonExistent ] )
-
Description
Move the browser's focus onto element.
This is accomplished by ensuring the the element has a tabindex attribute. By default, if the element had no tabindex attribute, the temporary one will be removed. Some browsers will update the activeElement after removing the tabindex.
Parameters
Name Type Attributes Default Description elementexternal:Element Element to focus on.
removeNonExistentboolean <optional> true Whether to remove the tabindex if it was originally not present.
Details
-
<static> focusOnTree( root )
-
Description
Move the browser's focus somewhere into the requested tree.
This uses a heuristic to find the first focusable element in a tree. If it is unable to find one, it falls back to forcing the requested element.
Parameters
Name Type Description rootexternal:Element The root of the tree
Details
-
<static> postInfoAboutElement( element, area )
-
Description
Post a bunch of information about an Element to
issues.Parameters
Name Type Description elementexternal:Element Element to get information about.
areastring What area this information came from.
Details
-
<static> isInput( element ) → {boolean}
-
Description
Determines if the element accepts keyboard input.
Parameters
Name Type Description elementexternal:Element Element to examine.
Returns
Details
-
<inner> otmotMoCallback( records, observer ) → {boolean}
-
Description
MutationObserver callback for otmot.
Parameters
Name Type Description recordsArray.<external:MutationRecord> Standard mutation records.
observerexternal:MutationObserver The invoking observer, enhanced with extra properties by otmot().
Returns
Details
-
<static> otmot( what, how ) → {Promise.<NexusHoratio.web~Results>}
-
Description
One time mutation observer with timeout.
Parameters
Name Type Description whatNexusHoratio.web~OtmotWhat What to observe.
howNexusHoratio.web~OtmotHow How to observe.
Returns
Details
-
<inner> otrotRoCallback( entries, observer ) → {boolean}
-
Description
ResizeObserver callback for otrot.
Parameters
Name Type Description entriesArray.<external:ResizeObserverEntry> Standard resize records.
observerNexusHoratio.web~ResizeObserver The invoking observer, enhanced with extra properties by otrot().
Returns
Details
-
<static> otrot( what, how ) → {Promise.<NexusHoratio.web~OtrotWhat>}
-
Description
One time resize observer with timeout.
Will resolve automatically upon first resize change.
Parameters
Name Type Description whatNexusHoratio.web~OtrotWhat What to observe.
howOtrotHow How to observe.
Returns
Details
-
<inner> otrot2RoCallback( entries, observer )
-
Description
ResizeObserver callback for otrot2.
Parameters
Name Type Description entriesArray.<external:ResizeObserverEntry> Standard resize records.
observerNexusHoratio.web~ResizeObserver The invoking observer, enhanced with extra properties by otrot().
Details
-
<static> waitForSelector( selector [, timeout [, base ] ] ) → {Promise.<external:Element>}
-
Description
Wait for selector to match using querySelector.
Parameters
Name Type Attributes Default Description selectorstring CSS selector.
timeoutnumber <optional> 0 Time to wait in milliseconds, 0 disables.
baseexternal:Element <optional> document Where to start looking.
Returns
Details
Type Definitions
-
Results
-
Description
Generic object representing results.
Details
-
Continuation
-
Properties
Name Type Attributes Description doneboolean Indicate whether the monitor is done processing.
resultsNexusHoratio.web~Results <optional> Results of an observation.
Details
-
Monitor( records ) → {NexusHoratio.web~Continuation}
-
Parameters
Name Type Description recordsArray.<external:MutationRecord> Standard mutation records.
Returns
Details
-
SimpleFunction()
-
Description
Simple function that takes no parameters and returns nothing.
Details
-
OtmotWhat
-
Properties
Name Type Description namestring The name for this observer.
baseexternal:Element Element to observe.
Details
-
OtmotHow
-
Properties
Name Type Attributes Description observeOptionsobject external:MutationObserverobserve()options.triggerNexusHoratio.web~SimpleFunction <optional> Function to call that triggers observable results.
monitorNexusHoratio.web~Monitor Callback used to process MutationObserver records.
timeoutnumber <optional> Time to wait for completion in milliseconds, default of 0 disables.
Details
-
OtrotWhat
-
Properties
Name Type Description namestring The name for this observer.
baseexternal:Element Element to observe.
Details
-
OtrotHow
-
Properties
Name Type Attributes Description triggerNexusHoratio.web~SimpleFunction <optional> Function to call that triggers observable events.
timeoutnumber Time to wait for completion in milliseconds.
Details
-
ResizeAction( entries )
-
Parameters
Name Type Description entriesArray.<external:ResizeObserverEntry> Standard resize entries.
Details
-
Otrot2How
-
Properties
Name Type Attributes Description triggerNexusHoratio.web~SimpleFunction <optional> Function to call that triggers observable events.
actionNexusHoratio.web~ResizeAction Function to call upon each event observed and also at the end of duration.
durationnumber Time to run in milliseconds.
Details