     Editor : 'Ace'
 
   constructor:(options = {}, data={})->
+
+    {curry, slugify, groupifyLink}   = KD.utils
+
     data.type        or= ''
     options.tagName  or= 'a'
     options.type     or= 'main-nav'
-    options.bind       = KD.utils.curry 'contextmenu', options.bind
+    options.bind       = curry 'contextmenu', options.bind
     options.draggable  = yes
-    options.cssClass   = KD.utils.curry @utils.slugify(data.title), options.cssClass
-    options.cssClass   = KD.utils.curry 'no-anim', options.cssClass
-    options.attributes = {}
-
-    {entryPoint} = KD.config
-    if entryPoint
-      {slug} = entryPoint
-      options.attributes.href = "/#{slug}#{data.path}"
-    else
-      options.attributes.href = data.path
+    options.cssClass   = curry slugify(data.title), options.cssClass
+    options.cssClass   = curry 'no-anim', options.cssClass
+    options.attributes =
+      href             : groupifyLink data.path
 
     super options, data
 

  pistachio:->
    """
      {{> @icon}}
      <span class='icon'></span>
      <cite>#{@name}</cite>
    """


      partial  : "<span class='logo'>#{@name[0]}</span>"
    @icon.setCss 'backgroundColor', KD.utils.getColorFromString @name

    appsWithIcon = Object.keys(KD.config.apps)
    appsWithIcon.push 'Editor'
    @icon.hide()  if @name in appsWithIcon and not data.useFakeIcon

    @on 'DragStarted', @bound 'dragStarted'


  setState:(state = 'initial')->
