Class: InstantSearchMobile

InstantSearchMobile()

Instant search on mobile

Extends

Members

(static) tempType :Object

Enum of Insatant search mobile templates (SEARCH_BTN, DEFAULT)
Type:
  • Object
Source:

children :Array

Array of child components
Type:
  • Array
Overrides:
Default Value:
  • []
Source:

parent :Component

The parent component
Type:
  • Component
Overrides:
Default Value:
  • null
Source:

Methods

(static) isActive()

Returns whether or not this instant search result mobile is used
Source:

_callAllBindEvents()

Bind events on the component (include all child-components)
Overrides:
Source:

_callAllInit()

Initialize the component (include all child-components)
Overrides:
Source:

_callAllRender()

Render the component (include all child-components)
Overrides:
Source:

_onClickSearchBox(event)

Bind the click evnet on the search input to open the search box on mobile
Parameters:
Name Type Description
event Event DOM event
Source:

_onFocusSearchBox(event)

Bind the focus event on the search input to open the search box on mobile
Parameters:
Name Type Description
event Event DOM Event
Source:

_onTypeSearchBoxEvent(event)

Bind the typeahead event on the search input
Parameters:
Name Type Description
event *
Source:

_setValueAllSearchBoxes(value)

Update the current search term to all search inputs
Parameters:
Name Type Description
value *
Source:

addComponent(childComponent)

Add the child component into a component
Parameters:
Name Type Description
childComponent Object The child component
Overrides:
Source:

afterBindEvents()

After bind evnets on the component
Overrides:
Source:

afterCloseInstantSearchMobile(isClose)

After close the instant search mobile
Parameters:
Name Type Description
isClose String Close the search box or just close the instant search result
Source:

afterInit()

After initialize callback
Overrides:
Source:

afterRender()

After reder component callback
Overrides:
Source:

afterShowSearchBoxMobile()

After show the instant search mobile
Source:

beforeBindEvents()

Before bind events on component callback
Overrides:
Source:

beforeInit()

Before initialize callback
Overrides:
Source:

beforeRender()

Before reder component callback
Overrides:
Source:

bindEvents()

Bind the events on Instant search mobile
Overrides:
Source:

clearInstantSearchMobile()

Clear the current search term and instant search result
Source:

closeInstantSearchMobile(isClose)

Close search box on mobile
Parameters:
Name Type Description
isClose Boolean Close the search box or just close the instant search result
Source:

compileTemplate() → {String}

Replace the brackets in raw html template with proper values
Source:
Returns:
HTML string
Type
String

getTemplate(tempType) → {String}

Get the raw HTML template of Search box on mobile
Parameters:
Name Type Description
tempType String The template type: 'default' or 'search_btn'
Source:
Returns:
The raw HTML template
Type
String

init()

Initialize component
Overrides:
Source:

isBindEvents()

Returns whether or not the events are bind on instant search mobile
Overrides:
Source:

isLoopThroughChild()

Returns whether or not the childs of a component is refresh
Overrides:
Source:

isRender()

Returns whether or not the component is rendered
Overrides:
Source:

onClickOutsideSuggestionMobileEvent()

Bind the click event on outside of instant search mobile to close it.
Source:

openSuggestionMobile()

Open the instant search mobile
Source:

refresh()

Refresh component
Overrides:
Source:

removeComponent(childComponent)

Remove a child component of a component
Parameters:
Name Type Description
childComponent Object The child component
Overrides:
Source:

render()

Render the search box on mobile
Overrides:
Source:

scrollSuggestionMobileEvent()

Bind the scroll event on instant search mobile
Source:

showSearchBoxMobile()

Show search box in mobile
Source: