Commit 0f547c08 authored by 郭朴讴's avatar 郭朴讴

半导体样式

parent f659af65
...@@ -17,8 +17,9 @@ ...@@ -17,8 +17,9 @@
} }
.zkbtn{ .zkbtn{
position: absolute; position: absolute;
right: 0; right: 10px;
bottom: 0; bottom: 5px;
font-size: 12px;
color: #999; color: #999;
cursor: pointer; cursor: pointer;
} }
...@@ -212,7 +213,8 @@ ...@@ -212,7 +213,8 @@
}) })
$("#tab2 .txt p").each(function(){ $("#tab2 .txt p").each(function(){
console.log($(this).height());
if ($(this).height()>100) { if ($(this).height()>100) {
$(this).parent().parent().append("<div class='zkbtn'>展开</div>"); $(this).parent().parent().append("<div class='zkbtn'>展开</div>");
} }
...@@ -223,7 +225,9 @@ ...@@ -223,7 +225,9 @@
} }
}) })
$(".zkbtn").click(function(){ $(".zkbtn").click(function(event){
event.stopPropagation();
event.preventDefault();
$(this).parent().find("p").parent().toggleClass("tdiv"); $(this).parent().find("p").parent().toggleClass("tdiv");
if ($(this).parent().find("p").parent().hasClass("tdiv")) { if ($(this).parent().find("p").parent().hasClass("tdiv")) {
$(this).html("收起") $(this).html("收起")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment