default-theme/modules/e_paper/_latest_slider_full_screen....

74 lines
2.3 KiB
Plaintext
Raw Normal View History

2021-01-27 12:55:12 +00:00
<div class="latest-fullslider" >
<h3 class="e-annc__widget-title">
<span>{{widget-title}}</span>
</h3>
<div class="slide-button">
<button class="cycle-prev btn btn-default"> <i class="fa fa-angle-left"></i></button>
<button class="cycle-next btn btn-default"> <i class="fa fa-angle-right"></i></button>
<a class="e-paper btn btn-default pull-right" href="/zh_tw/epapers?method=papers"><%= (I18n.locale.to_s =="zh_tw") ? "更多 +" : "More NEWS" %></a>
</div>
<div class="e-paper cycle-slideshow"
data-level="0"
data-list="categories"
data-cycle-slides=".banner-Container"
data-cycle-fx="carousel"
data-cycle-log="false"
data-cycle-carousel-fluid=true
data-cycle-pause-on-hover="true"
data-cycle-speed="100"
data-cycle-carousel-visible="1"
data-cycle-prev=".cycle-prev"
data-cycle-next=".cycle-next"
data-cycle-swipe=true
data-cycle-swipe-fx="carousel"
>
<div class="banner-Container" data-list="topics" data-level="1">
<div class="item">
<div class="row epaper-container">
<div class="left-fullslider col-lg-7 col-xs-12">
<a href="{{link_to_show}}">
<img src="{{img_url_thumb}}" alt="{{title}}">
</a>
</div>
<div class="right-fullslider col-lg-5 col-xs-12">
<div class="right-box">
<a href="{{link_to_show}}">
<h3>{{category_title}}</h3>
<h4>{{title}}</h4>
<div class="epaper-description">{{description}}</div>
</a>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$(function(){
var len = 200;
$(".latest-fullslider .epaper-description").each(function(i){
if($(this).text().length>len){
$(this).attr("title",$(this).text());
var text=$(this).text().substring(0,len-1)+" ...";
$(this).text(text);
}
});
});
if ($(window).width() < 768) {
$(function(){
var len = 80;
$(".latest-fullslider .epaper-description").each(function(i){
if($(this).text().length>len){
$(this).attr("title",$(this).text());
var text=$(this).text().substring(0,len-1)+" ...";
$(this).text(text);
}
});
});
}
</script>