NewsTicker

NewsTicker

new NewsTicker(element, options)

Source:
Parameters:
Name Type Description
element HTMLElement

DOM element for component instantiation and scope

options Object
Properties
Name Type Description
toggleSelector String

Selector for toggling element

prevSelector String

Selector for prev element

nextSelector String

Selector for next element

contentClass String

Selector for the content container

slidesClass String

Selector for the slides container

slideClass String

Selector for the slide items

currentSlideClass String

Selector for the counter current slide number

Classes

NewsTicker

Methods

checkIndex()

Description:
  • Action to update slides index and position.

Source:

destroy()

Description:
  • Destroy component.

Source:

handleAutoPlay()

Description:
  • Toggles play/pause slides.

Source:

handleFocus(e)

Description:
  • Trigger events on focus.

Source:
Parameters:
Name Type Description
e Event

handleMouseOut()

Description:
  • Trigger events on mouseout.

Source:

handleMouseOver()

Description:
  • Trigger events on mouseover.

Source:

handleResize()

Description:
  • Trigger events on resize.

Source:

init()

Description:
  • Initialise component.

Source:

moveSlides(transition)

Description:
  • Transition for the slides.

Source:
Parameters:
Name Type Description
transition Boolean

shiftSlide(dir, stopAutoPlay)

Description:
  • Action to shift next or previous slide.

Source:
Parameters:
Name Type Description
dir int
stopAutoPlay Boolean

(static) autoInit(root) → {NewsTicker}

Source:
Parameters:
Name Type Description
root HTMLElement

DOM element for component instantiation and scope

Returns:

An instance of News ticker.

Type
NewsTicker