Reference Source
public class | source

RenderedDDom

Extends:

devapt-core-common/dist/js/base/stateable~StateableDom → RenderedDDom

Constructor Summary

Public Constructor
public

constructor(arg_runtime: RuntimeBase, arg_state: Immutable.Map, arg_log_context: string): nothing

Creates an instance of RenderedDom.

Member Summary

Public Members
public
public
public
Private Members
private
private
private
private

Method Summary

Public Methods
public

add_assets_dependancy(arg_asset_id: string): nothing

Add assets dependancy.

public

Destroy component DOM element.

public

Get assets dependancies.

public

Get assets promises.

public

init_assets(): nothing

Init assets promises.

public

process_rendering_vnode(arg_rendering_result: *, arg_credentials: *)

PROCESS RENDERING VNODE: CREATE OR UPDATE DOM ELEMENT.

public

render(arg_force: boolean): Promise

Render component DOM element.

public

save_rendering(): nothing

Save rendering virtul node.

public

update_size(): nothing

Update component size with its content.

Private Methods
private

_render(arg_force: *): *

Inherited Summary

From class Dom
public
private
private

_name: *

private
private
public

clear_dom_text(): nothing

DOM element manipulation:clear dom element text value.

public

clear_dom_value(): nothing

DOM element manipulation:clear dom element value.

public

get_dom_attr(arg_attr_name: string): string

DOM element manipulation:get dom element attribute.

public

get_dom_element(): Element

Get DOM element.

public

Get DOM id.

public

get_dom_parent(): Element

Get parent element.

public

DOM element manipulation:get dom element text.

public

DOM element manipulation:get dom element value.

public

get_dom_vnode(): VNode

Get DOM Virtual Node.

public

Get name.

public

Test DOM Element instance.

public

has_dom_parent(arg_element: Element): boolean

Test if component element has given parent element.

public

Test DOM Virtual Node.

public

hide(): nothing

Hide component.

public

is_visible(arg_check: boolean): boolean

Get visibility.

public

on_dom_event(arg_dom_event: *, arg_dom_selector: *, arg_handler: *, arg_data: *, arg_debug: boolean): nothing

Mount dom event handler.

public

set_dom_attr(arg_attr_name: string, arg_attr_value: string): nothing

DOM element manipulation:set dom element attribute value.

public

set_dom_element(arg_element: Element): nothing

Set DOM element.

public

set_dom_parent(arg_parent_element: Element): nothing

Set given parent element.

public

set_dom_parent_of(arg_component: Component): nothing

Set given parent element.

public

set_dom_text(arg_text_value: string): nothing

DOM element manipulation:set dom element text value.

public

set_dom_value(arg_value: string): nothing

DOM element manipulation:set dom element value.

public

set_dom_vnode(arg_vnode: VNode): nothing

Set DOM Virtual Node.

public

show(): nothing

Show component.

public

toggle(): nothing

Toggle component visbility.

private

_get_dom_text(arg_element: *): *

Public Constructors

public constructor(arg_runtime: RuntimeBase, arg_state: Immutable.Map, arg_log_context: string): nothing source

Creates an instance of RenderedDom.

Override:

Dom#constructor

Params:

NameTypeAttributeDescription
arg_runtime RuntimeBase

client runtime.

arg_state Immutable.Map

component initial state.

arg_log_context string

context of traces of this instance (optional).

Return:

nothing

Public Members

public is_breadcrumbs: boolean source

public is_menubar: boolean source

public is_rendered_dom: boolean source

Private Members

private _assets_dependancies: *[] source

private _assets_promise: * source

private _is_visible: boolean source

Override:

Dom#_is_visible

private _ready_promise: * source

Public Methods

public add_assets_dependancy(arg_asset_id: string): nothing source

Add assets dependancy.

Params:

NameTypeAttributeDescription
arg_asset_id string

asset element id.

Return:

nothing

public destroy(): Promise source

Destroy component DOM element.

Return:

Promise

public get_assets_dependancies(): array source

Get assets dependancies.

Return:

array

public get_assets_promise(): Promise source

Get assets promises.

Return:

Promise

public init_assets(): nothing source

Init assets promises.

Return:

nothing

public process_rendering_vnode(arg_rendering_result: *, arg_credentials: *) source

PROCESS RENDERING VNODE: CREATE OR UPDATE DOM ELEMENT.

Params:

NameTypeAttributeDescription
arg_rendering_result *
arg_credentials *

public render(arg_force: boolean): Promise source

Render component DOM element.

Params:

NameTypeAttributeDescription
arg_force boolean

should force creation of a new VNode if a previous rendering exists.

Return:

Promise

Promise of this to chain promises.

public save_rendering(): nothing source

Save rendering virtul node. Update component VNode with current component HTML.

Return:

nothing

public update_size(): nothing source

Update component size with its content.

Return:

nothing

Private Methods

private _render(arg_force: *): * source

Params:

NameTypeAttributeDescription
arg_force *

Return:

*