--- a/integration/js/main.js Mon Oct 08 17:31:29 2012 +0200
+++ b/integration/js/main.js Tue Oct 09 10:45:44 2012 +0200
@@ -1,5 +1,5 @@
$(function(){
- //CLUSTER
+//CLUSTER
var clusterWidth=0;
$('.cluster li').each( function(){ clusterWidth += $(this).width() + 10; });
$('.cluster').width( clusterWidth );
@@ -41,14 +41,13 @@
});
}
}
-
});
-
//DRAGGABLE
$(".cluster").draggable({ axis: "x",containment: ".cluster-containment" });
};
- //WIDGET
+//WIDGET
+ //VOLET
//$("div.content-left div.widget-wrap div.widget div.widget-inner").hide();
$("div.content-left div.widget-wrap div.widget h3 a").bind("click",function(e){
e.preventDefault();
@@ -62,7 +61,18 @@
$(this).addClass("open");
}
});
- //DOCUMENTAIRE
+ //AFFICHAGE
+ $('.widget.affichage li a').bind('click',function(e){
+ e.preventDefault();
+ if ($(this).hasClass("treemap") && !$(this).hasClass("active")) {
+ $('.widget.affichage li a.liste').removeClass("active");
+ $(this).addClass('active');
+ }else if($(this).hasClass("liste") && !$(this).hasClass("active")){
+ $('.widget.affichage li a.treemap').removeClass("active");
+ $(this).addClass('active');
+ }
+ });
+//VOLET DOCUMENTAIRE
$("div.dossier-documentaire").hide();
$("div.header a.dossier-button").bind("click",function(e){
e.preventDefault();
@@ -73,13 +83,30 @@
$("div.dossier-documentaire").slideDown();
}
});
- //ARTICLES
+//ARTICLES
$(".article-visuel-wrap").each(function(){
var contentHeight = $(this).parents(".article-content").height();
-
//$(this).height(contentHeight);
});
+//FRISE
+ //valeurs init du slider à définir
+ var valSlider1 = 75;
+ var valSlider2 = 500;
+ var widthFrise = $('.frise').width();
+ $( "#slider-range" ).slider({
+ range: true,
+ min: 0,
+ max: widthFrise,
+ values: [ valSlider1, valSlider2 ],
+ create: function(event, ui){
+
+ $(".voile-left").width(valSlider1);
+ $(".voile-right").width(widthFrise-valSlider2);
+ },
+ slide: function( event, ui ) {
-
-
-});
+ $(".voile-left").width(ui.values[ 0 ]);
+ $(".voile-right").width(widthFrise-ui.values[ 1 ]);
+ }
+ });
+});//jQuery