Index: /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/pom.xml
===================================================================
--- /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/pom.xml	(revision 974)
+++ /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/pom.xml	(revision 975)
@@ -138,4 +138,11 @@
 
     <repository>
+      <id>wiquery repository</id>
+      <name>wiQuery repository</name>
+      <url>http://wiquery.googlecode.com/svn/repo/</url>
+      <layout>default</layout>
+    </repository>
+
+    <repository>
       <id>repository.clarin</id>
       <name>CLARIN Repository</name>
@@ -278,4 +285,8 @@
           <artifactId>jaxb-impl</artifactId>
         </exclusion>
+        <exclusion>
+        	<artifactId>jackson-mapper-asl</artifactId>
+        	<groupId>org.codehaus.jackson</groupId>
+        </exclusion>
       </exclusions>
     </dependency>
@@ -327,4 +338,10 @@
 
     <dependency>
+      <groupId>org.odlabs.wiquery</groupId>
+      <artifactId>wiquery</artifactId>
+      <version>1.1.2</version>
+    </dependency>
+
+    <dependency>
       <groupId>net.java.dev.javacc</groupId>
       <artifactId>javacc</artifactId>
@@ -367,8 +384,44 @@
   <dependencyManagement>
   	<dependencies>
+     <dependency>
+       <groupId>commons-codec</groupId>
+       <artifactId>commons-codec</artifactId>
+       <version>1.4</version>
+      </dependency>
+
+      <dependency>
+        <groupId>org.codehaus.jettison</groupId>
+        <artifactId>jettison</artifactId>
+        <version>1.2</version>
+      </dependency>
+
+      <dependency>
+        <groupId>org.apache.wicket</groupId>
+        <artifactId>wicket</artifactId>
+        <version>${wicket.version}</version>
+      </dependency>
+
       <dependency>
         <groupId>org.slf4j</groupId>
         <artifactId>slf4j-api</artifactId>
         <version>${slf4j.version}</version>
+      </dependency>
+
+      <dependency>
+        <groupId>org.slf4j</groupId>
+        <artifactId>slf4j-jdk14</artifactId>
+        <version>${slf4j.version}</version>
+      </dependency>
+
+      <dependency>
+        <groupId>org.codehaus.jackson</groupId>
+        <artifactId>jackson-core-asl</artifactId>
+        <version>1.6.1</version>
+      </dependency>
+
+      <dependency>
+        <groupId>org.codehaus.jackson</groupId>
+        <artifactId>jackson-mapper-asl</artifactId>
+        <version>1.6.1</version>
       </dependency>
   	</dependencies>
Index: /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/border/AjaxToggleBorder.html
===================================================================
--- /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/border/AjaxToggleBorder.html	(revision 974)
+++ /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/border/AjaxToggleBorder.html	(revision 975)
@@ -6,29 +6,4 @@
 <head />
 <body>
-<wicket:head>
-<script type="text/javascript" src="js/jquery.js"></script>
-<script type="text/javascript">
-var $j = jQuery.noConflict();
-$j(document).ready(function() {
-	$j('div.toggleBorderHeader.hidden ~ div.toggleBorderContent').hide();
-	$j('div.toggleBorderHeader').click(function() {
-		var $h = $j(this);
-		var $c = $j(this).next('div.toggleBorderContent');
-		if ($h.hasClass('shown')) {
-			$c.slideUp('slow', function() {
-	            $h.removeClass('shown');
-	            $h.addClass('hidden');
-			});
-		} else {
-            $c.slideDown('slow', function() {
-                $h.removeClass('hidden');
-                $h.addClass('shown');
-            });
-		}
-		return true;
-	});
-});
-</script>
-</wicket:head>
 <wicket:border>
   <div class="toggleBorder">
Index: /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/border/AjaxToggleBorder.java
===================================================================
--- /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/border/AjaxToggleBorder.java	(revision 974)
+++ /VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/border/AjaxToggleBorder.java	(revision 975)
@@ -5,11 +5,20 @@
 import org.apache.wicket.markup.html.basic.Label;
 import org.apache.wicket.markup.html.border.Border;
-import org.apache.wicket.model.AbstractReadOnlyModel;
 import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.odlabs.wiquery.core.effects.EffectSpeed;
+import org.odlabs.wiquery.core.effects.sliding.SlideToggle;
+import org.odlabs.wiquery.core.events.Event;
+import org.odlabs.wiquery.core.events.MouseEvent;
+import org.odlabs.wiquery.core.events.WiQueryEventBehavior;
+import org.odlabs.wiquery.core.javascript.JsScope;
+import org.odlabs.wiquery.core.javascript.JsStatement;
 
 @SuppressWarnings("serial")
 public class AjaxToggleBorder extends Border {
-
-    public AjaxToggleBorder(String id, IModel<String> title, final boolean expanded) {
+    private final static String COLLAPSED_CLASS = "collapsed";
+    
+    public AjaxToggleBorder(String id, IModel<String> title,
+            final boolean expanded) {
         super(id);
         setRenderBodyOnly(true);
@@ -17,15 +26,28 @@
         final WebMarkupContainer header = new WebMarkupContainer("header");
         header.add(new Label("title", title));
-        header.add(new AttributeAppender("class",
-                new AbstractReadOnlyModel<String>() {
-                    @Override
-                    public String getObject() {
-                        return expanded ? "shown" : "hidden";
-                    }
-                }, " "));
+
+        final WebMarkupContainer content = new WebMarkupContainer("content");
+        content.setOutputMarkupId(true);
+        content.add(getBodyContainer());
         add(header);
-        final WebMarkupContainer content = new WebMarkupContainer("content");
-        content.add(getBodyContainer());
         add(content);
+
+        header.add(new WiQueryEventBehavior(new Event(MouseEvent.CLICK) {
+            @Override
+            public JsScope callback() {
+                final JsScope cb = JsScope.quickScope(new JsStatement()
+                    .$(header).toggleClass(COLLAPSED_CLASS));
+                final SlideToggle effect = new SlideToggle(EffectSpeed.SLOW);
+                effect.setCallback(cb);
+                return JsScope.quickScope(new JsStatement()
+                    .$(content).chain(effect));
+            }
+        }));
+        if (!expanded) {
+            header.add(new AttributeAppender("class",
+                    new Model<String>(COLLAPSED_CLASS), " "));
+            content.add(new AttributeAppender("style",
+                    new Model<String>("display:none"), ";"));
+        }
     }
 
