/**
 * HTML Component
 * --------------
 * allows the insertion of arbitrary HTML into an entity
 */
Crafty.c("HTML", {
	inner: '',
	
	init: function () {
		this.requires('2D DOM');
	},
	
	replace: function (new_html) {
		this.inner = new_html;
		this._elem.innerHTML = new_html;
	},
	
	append: function (new_html) {
		this.inner += new_html;
		this._elem.innerHTML += new_html;
	},
	
	prepend: function (new_html) {
		this.inner = new_html + this.inner;
		this._elemn.innerHTML = new_html + this.inner;
	},
});
@@ -1,57 +1,59 @@
 /**
+@
 %0A
- 
 * 
+#
 HTML
- Component%0A * --------------%0A *
+%0A* @category Graphics%0A* Component
  allow
-s the
+ for
  ins
@@ -92,17 +92,16 @@
  entity%0A
- 
 */%0ACraft
@@ -168,16 +168,17 @@
 ires('2D
+,
  DOM');%0A
@@ -181,17 +181,382 @@
 ');%0A%09%7D,%0A
-%09
+%0A%09/**@%0A%09* #.replace%0A%09* @comp HTML%0A%09* @sign public this .replace(String html)%0A%09* @param html - arbitrary html%0A%09* This method will replace the content of this entity with the supplied html%0A%09*%0A%09* @example%0A%09* Create a link%0A%09* ~~~%0A%09* Crafty.e(%22HTML%22)%0A%09*    .attr(%7Bx:20, y:20, w:100, h:100%7D)%0A    *    .replace(%22%3Ca href='http://www.craftyjs.com'%3ECrafty.js%3C/a%3E%22);%0A%09* ~~~%0A%09*/
 %0A%09replac
@@ -609,32 +609,35 @@
 ml;%0A%09%09this._elem
+ent
 .innerHTML = new
@@ -647,17 +647,375 @@
 ml;%0A%09%7D,%0A
-%09
+%0A%09/**@%0A%09* #.replace%0A%09* @comp HTML%0A%09* @sign public this .append(String html)%0A%09* @param html - arbitrary html%0A%09* This method will add the supplied html in the beginning of the entity%0A%09*%0A%09* @example%0A%09* Create a link%0A%09* ~~~%0A%09* Crafty.e(%22HTML%22)%0A%09*    .attr(%7Bx:20, y:20, w:100, h:100%7D)%0A    *    .append(%22%3Ca href='http://www.craftyjs.com'%3ECrafty.js%3C/a%3E%22);%0A%09* ~~~%0A%09*/
 %0A%09append
@@ -1076,16 +1076,19 @@
 is._elem
+ent
 .innerHT
@@ -1107,17 +1107,371 @@
 ml;%0A%09%7D,%0A
-%09
+%0A%09/**@%0A%09* #.replace%0A%09* @comp HTML%0A%09* @sign public this .prepend(String html)%0A%09* @param html - arbitrary html%0A%09* This method will add the supplied html in the end of the entity%0A%09*%0A%09* @example%0A%09* Create a link%0A%09* ~~~%0A%09* Crafty.e(%22HTML%22)%0A%09*    .attr(%7Bx:20, y:20, w:100, h:100%7D)%0A    *    .prepend(%22%3Ca href='http://www.craftyjs.com'%3ECrafty.js%3C/a%3E%22);%0A%09* ~~~%0A%09*/
 %0A%09prepen
@@ -1545,17 +1545,19 @@
 is._elem
-n
+ent
 .innerHT
@@ -1586,13 +1586,12 @@
 nner;%0A%09%7D
-,
 %0A%7D);

fix html component and add doc