Home Reference Source Test Repository
public class | source

ArticleBodyComponent

Extends:

src/core/bane~Component → ArticleBodyComponent

Enhances the body of articles with a gallery and more

Member Summary

Public Members
public

gallery: *

public
public
public

poiData: *

Method Summary

Public Methods
public

Format the post date with moment.js

public

initialize(options: *)

public

Preload an image

public

Loads all the images in the body of the article

public

Creates a new instance of the POI callout

Public Members

public imageContainerSelector: string source

public poiCallout: * source

public poiData: * source

Public Methods

public formatDate() source

Format the post date with moment.js

public initialize(options: *) source

Params:

NameTypeAttributeDescription
options *

public loadImage(url: String): Promise source

Preload an image

Params:

NameTypeAttributeDescription
url String

Url of the image to load

Return:

Promise

A promise for when the image loads

public loadImages(): Promise source

Loads all the images in the body of the article

Return:

Promise

A promise for when all of the images have loaded

public loadPoiCallout(data: Object) source

Creates a new instance of the POI callout

Params:

NameTypeAttributeDescription
data Object

POI data