lib/packages/core-classes.js
function(element) {

		var Element = Firestorm.Element,
			name;

		if (this._is_inDOM) Lava.t("Can not set duplicate id attribute on elements");
		// there must not be ID attribute
		if (Element.getProperty(element, 'id')) Lava.t("Target element already has an ID, and could be owned by another container");
		if (Element.getProperty(element, 'tag').toLowerCase() != this._tag_name) Lava.t("Captured tag name differs from the container's tag name");

		Element.setProperty(element, 'id', this._id);

		this._is_inDOM = true;
		this._element = element;

		for (name in this._static_properties) {

			// note: escaping must be handled by framework
			Element.setProperty(element, name, this._static_properties[name]);

		}

		for (name in this._property_bindings) {

			Element.setProperty(element, name, this._property_bindings[name].getValue());

		}

		this.syncClasses();
		this.syncStyles();
		this._is_element_owner = false;

	}
function(element) {

		var Element = Firestorm.Element,
			name;

		if (this._is_inDOM) Lava.t("Can not set duplicate id attribute on elements");
		// there must not be ID attribute
		if (Element.getProperty(element, 'id')) Lava.t("Target element already has an ID, and could be owned by another container");
		if (Element.getProperty(element, 'tag').toLowerCase() != this._tag_name) Lava.t("Captured tag name differs from the container's tag name");

		Element.setProperty(element, 'id', this._id);

		this._is_inDOM = true;
		this._element = element;

		for (name in this._static_properties) {

			// note: escaping must be handled by framework
			Element.setProperty(element, name, this._static_properties[name]);

		}

		for (name in this._property_bindings) {

			Element.setProperty(element, name, this._property_bindings[name].getValue());

		}

		this.syncClasses();
		this.syncStyles();
		this._is_element_owner = false;

	}
function ( element ) { var Element = Firestorm . Element , name ; if ( this . _is_inDOM ) Lava . t ( "Can not set duplicate id attribute on elements" ) ; // there must not be ID attribute if ( Element . getProperty ( element , 'id' ) ) Lava . t ( "Target element already has an ID, and could be owned by another container" ) ; if ( Element . getProperty ( element , 'tag' ) . toLowerCase ( ) != this . _tag_name ) Lava . t ( "Captured tag name differs from the container's tag name" ) ; Element . setProperty ( element , 'id' , this . _id ) ; this . _is_inDOM = true ; this . _element = element ; for ( name in this . _static_properties ) { // note: escaping must be handled by framework Element . setProperty ( element , name , this . _static_properties [ name ] ) ; } for ( name in this . _property_bindings ) { Element . setProperty ( element , name , this . _property_bindings [ name ] . getValue ( ) ) ; } this . syncClasses ( ) ; this . syncStyles ( ) ; this . _is_element_owner = false ; }
Bind container to existing DOM element. Apply new styles, classes and properties
@param {HTMLElement} element
Bind container to existing DOM element . Apply new styles classes and properties