diff --git a/dev/js/src/hint.js b/dev/js/src/hint.js
index 89003ee..16b3f8b 100644
--- a/dev/js/src/hint.js
+++ b/dev/js/src/hint.js
@@ -9,6 +9,11 @@
  * TODO: Sometimes the drop-down box down vanish when list is shown
  * TODO: Create should expect an input text field
  * TODO: Embed only one single menu (not multiple)
+ *       By holding the current menu in _active
+ * TODO: show() should accept a context field (especially for no-context fields,
+ *       like fragments)
+ * TODO: Improve context analyzer from hint!
+ * TODO: Marked annotations should be addable to "fragments"
  */
 define([
   'hint/input',
@@ -70,7 +75,7 @@
       // Holds all menus per prefix context
       this._menu   = {};
       this._alert  = alertClass.create();
-      this._active = false;
+      this._active = null;
 
       // Get input field
       var qfield = param["inputField"] || document.getElementById("q-field");
@@ -146,19 +151,19 @@
       // Set container to active (aka hide the hint helper button)
 
       this._alert.show(msg);
-      this.active(true);
+      this.active(this._alert);
       return true;
     },
 
     _unshowAlert : function () {
-      this._alert.unshow();
-      this.active(false);
+      this._alert.hide();
+      this.active(null);
     },
 
     update : function () {
       this._inputField.update();
-      if (this._alert.unshow())
-	this.active(false);
+      if (this._alert.hide())
+	this.active(null);
     },
 
 
@@ -186,29 +191,32 @@
      * Get the correct menu based on the context
      */
     contextMenu : function (ifContext) {
+
+      // Get context (aka left text)
       var context = this._inputField.context();
 
-      if (context === undefined || context.length == 0)
+      if (context === undefined || context.length === 0)
 	return ifContext ? undefined : this.menu("-");
 
+      // Get context (aka left text matching regex)
       context = this._analyzer.test(context);
 
       if (context === undefined || context.length == 0)
 	return ifContext ? undefined : this.menu("-");
 
-      return this.menu(context);
+      return this.menu(context) || this.menu('-');
     },
 
-    active : function (bool) {
+    active : function (obj) {
       if (arguments.length === 1) {
 	var c = this._inputField.container();
-	if (bool && !this._active) {
+	if (obj !== null) {
 	  c.classList.add('active');
-	  this._active = true;
+	  this._active = obj;
 	}
 	else {
 	  c.classList.remove('active');
-	  this._active = false;
+	  this._active = null;
 	}
       };
       return this._active;
@@ -219,23 +227,43 @@
      * Show the menu.
      * Currently this means that multiple menus may be loaded
      * but not shown.
+     *
+     * @param {boolean} Boolean value to indicate if context
+     *        is necessary (true) or if the main context should
+     *        be shown if context fails.
+     *        
      */
     show : function (ifContext) {
 
+      var c = this._inputField.container();
+
       // Menu is already active
-      if (this.active()) {
+      if (this.active() !== null) {
+
+	// This does not work for alert currently!
+	if (this._active._type !== 'alert') {
+	  c.removeChild(this._active.element());
+	};
+
+	// This may already be hidden!
+	this._active.hide();
+	this.active(null);
 
 	// Alert is not active
-	if (!this._alert.unshow())
+	/*
+	  if (!this._alert.unshow())
 	  return;
+	*/
       };
 
       // Get the menu
       var menu;
       if (menu = this.contextMenu(ifContext)) {
-	var c = this._inputField.container();
-	this.active(true);
-	// c.classList.add('active');
+
+// TODO: Remove old element!
+
+	this.active(menu);
+
 	c.appendChild(menu.element());
 	menu.show();
 	menu.focus();
@@ -244,8 +272,16 @@
       };
     },
 
+    // Show an object in the containerField
+    // This will hide all other objects
+    // Accepts menus as well as alerts
+    show2 : function (obj) {},
+
+    // This will get the context of the field
+    getContext : function () {},
+
     unshow : function () {
-      this.active(false);
+      this.active(null);
       this.inputField().element().focus();
     }
   };
diff --git a/dev/js/src/hint/alert.js b/dev/js/src/hint/alert.js
index a5b43de..f34fde8 100644
--- a/dev/js/src/hint/alert.js
+++ b/dev/js/src/hint/alert.js
@@ -8,6 +8,7 @@
       return Object.create(this)._init(msg);
     },
     _init : function (msg) {
+      this._type = 'alert';
       this.active = false;
       this._element = document.createElement('div');
       this._element.style.opacity = 0;
@@ -20,7 +21,7 @@
       this._element.style.opacity = 1;
     },
 
-    unshow : function () {
+    hide : function () {
       if (!this.active)
 	return false;
       this._element.style.opacity = 0;
diff --git a/dev/js/src/hint/item.js b/dev/js/src/hint/item.js
index 3747a72..cfea816 100644
--- a/dev/js/src/hint/item.js
+++ b/dev/js/src/hint/item.js
@@ -22,8 +22,6 @@
       this._name   = params[0];
       this._action = params[1];
       this._lcField = ' ' + this._name.toLowerCase();
-
-      console.log('!!!!');
       
       if (params.length > 2) {
 	this._desc = params[2];
@@ -50,7 +48,7 @@
     onclick : function (e) {
       var m = this.menu();
       var h = m.hint();
-      m.hide();
+      // m.hide();
 
       // Update input field
       var input = h.inputField();
@@ -58,6 +56,7 @@
 
       e.halt();
 
+      // show alt
       h.show(true);
     },
 
diff --git a/dev/js/src/match.js b/dev/js/src/match.js
index 07a46ec..28d2154 100644
--- a/dev/js/src/match.js
+++ b/dev/js/src/match.js
@@ -7,6 +7,7 @@
 /*
  * - Highlight (at least mark as bold) the match
  * - Scroll to match vertically per default
+ * - A click on a table field and a tree node should at the field description to the fragments list.
  */
 define([
   'match/info',
diff --git a/dev/js/src/menu.js b/dev/js/src/menu.js
index 9f91e96..8619d89 100644
--- a/dev/js/src/menu.js
+++ b/dev/js/src/menu.js
@@ -11,6 +11,8 @@
  * TODO: Add a "title" to a menu that is not scrollable.
  * TODO: Make the menu responsive by showing less items on smaller screens
  *       or anytime items would be outside the screen.
+ * TODO: Add a .match() method to items for scrolling and probably for prefixing.
+ * TODO: Add static header (for title, sortation fields, but also for menu points like "fragments" and "history".
  */
 define([
   'menu/item',
