File

projects/components/widgets/prefab/src/prefab.component.doc.ts

Description

The wmPrefab component defines the prefab widget.

Index

Methods
Inputs

Methods

onAttach
onAttach($event: any, widget: any)

Callback function which will be triggered when a saved cached host page instance is attached to dom.

Parameters :
Name Type Optional Description
$event any No

DOM event on which call back is triggered

widget any No

Instance of the prefab widget

Returns : void
onDestroy
onDestroy($event: MouseEvent, widget: any)

Callback function which will be triggered when the widget is being destroyed.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the prefab widget

Returns : void
onDetach
onDetach($event: any, widget: any)

Callback function which will be triggered when a reusable host page instance is detached from dom.

Parameters :
Name Type Optional Description
$event any No

DOM event on which call back is triggered

widget any No

Instance of the prefab widget

Returns : void
onLoad
onLoad($event: MouseEvent, widget: any)

Callback function which will be triggered when the widget is loading.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the prefab widget

Returns : void
onOrientationchange
onOrientationchange($event: MediaQueryListEvent)

Callback function which will be triggered when screen orientation is changed.

Parameters :
Name Type Optional Description
$event MediaQueryListEvent No

DOM event on which call back is triggered

Returns : void
onResize
onResize($event: Event, widget: any, data: object)

Callback function which will be triggered when window is resized.

Parameters :
Name Type Optional Description
$event Event No

DOM event on which call back is triggered

widget any No

Instance of the page

data object No

this is an object which contains screen width and screen height

Returns : void

Inputs

class
Type : string

Class of the widget.

name
Type : string

Name(Unique across the web page) of the prefab widget.

prefabname
Type : string

Name of prefab to be rendered inside the prefab widget

show
Type : boolean
Default value : true

This property will be used to show/hide the prefab widget on the web page.

Bindable: true

results matching ""

    No results matching ""