Sha256: efd845ef9bb8afe182ff61d017603c99476a36ccf139d74c5c70ce4a7c63f9e7
Contents?: true
Size: 1.52 KB
Versions: 2
Compression:
Stored size: 1.52 KB
Contents
//javascript for main activities input $("#activities_share_btn").hide(); title = "<%= t('activity.input') %>"; $("#input_activities").click(function(){ if(this.value == title){ this.value=""; $("#activities_share_btn").show(); } }); $("#input_activities").blur(function(){ if(this.value == ""){ this.value= title; $("#activities_share_btn").hide(); } }); //javascript for comments $(".input_new_comments").val("<%= t('comment.input') %>"); $(".activities_comment_btn").hide(); //usa livequery para usar el javascript luego de una accion con AJAX $(".input_new_comments").livequery("click",function(){ if(this.value == "<%= t('comment.input') %>"){ $(this).val(""); } $(".activities_comment_btn").hide(); $(this).parent(".new_comment").children(".activities_comment_btn").show(); }); $(".input_new_comments").livequery("blur",function(){ if(this.value == ""){ $(".activities_comment_btn").hide(); $(this).val("<%= t('comment.input') %>"); } }); $(".input_new_comments").click(function(){ if(this.value == "<%= t('comment.input') %>"){ $(this).val(""); } $(".activities_comment_btn").hide(); $(this).parent(".new_comment").children(".activities_comment_btn").show(); }); //javascript for tocomment option $(".to_comment").livequery("click", function(){ $(this).parents(".activity_content").find(".input_new_comments").click(); return false; }); $(".to_comment").livequery("blur", function(){ $(this).parents(".activity_content").find(".input_new_comments").blur(); return false; }); $(".boxy").boxy();
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
social_stream-0.0.4 | app/views/activities/_jquery.html.erb |
social_stream-0.0.3 | app/views/activities/_jquery.html.erb |