update template
This commit is contained in:
parent
380f8916d0
commit
e9bfd5b314
|
@ -22,7 +22,14 @@
|
|||
|
||||
//RWD
|
||||
@import "RWD";
|
||||
.navFixed .modules-menu .modules-menu-level-0 > li:focus-within .modules-menu-level-1, .navRel .modules-menu .modules-menu-level-0 > li:focus-within .modules-menu-level-1{
|
||||
visibility: visible;
|
||||
max-height: 65%;
|
||||
opacity: 1;
|
||||
border-radius: 0.5em;
|
||||
padding: 1em 5% 3em;
|
||||
|
||||
}
|
||||
div.extra-box:empty {
|
||||
display: none;
|
||||
}
|
||||
|
@ -186,4 +193,4 @@ h3.page-module-title {
|
|||
.title-wraper{
|
||||
width: 100%;
|
||||
order: 1;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,69 +0,0 @@
|
|||
<div class="w-ba-banner ad-banner-widget-6 ba-banner-widget-6">
|
||||
<div class="w-ba-banner__wrap cycle-slideshow"
|
||||
data-list="images"
|
||||
data-level="0"
|
||||
data-cycle-slides=".w-ba-banner__slide"
|
||||
data-cycle-log="false"
|
||||
data-overlay=".w-ad-banner__overlay_{{subpart-id}}"
|
||||
data-cycle-auto-height="{{base_image}}"
|
||||
data-cycle-speed="{{speed}}"
|
||||
data-cycle-timeout="{{timeout}}"
|
||||
data-cycle-fx="{{ad_fx}}"
|
||||
data-cycle-pager=".banner_caption_{{subpart-id}}"
|
||||
data-pager-template=""
|
||||
data-pager-active-class="active-slide"
|
||||
data-cycle-swipe=true
|
||||
data-cycle-swipe-fx="scrollHorz"
|
||||
>
|
||||
<div class="w-ba-banner__slide {{class}}"
|
||||
data-link="{{link}}"
|
||||
data-cycle-title="{{title}}"
|
||||
data-cycle-desc="{{context}}"
|
||||
data-overlay-template="<h3>{{title}}</h3><p>{{desc}}</p>"
|
||||
data-target="{{target}}"
|
||||
>
|
||||
<a href="{{link}}" target="{{target}}" title="{{alt_title}}">
|
||||
<img class="w-ba-banner__image banner-responsive" src="{{image_link}}" alt="{{alt_title}}">
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="ad-overlay w-ba-banner__caption w-ad-banner__caption w-ad-banner__overlay_{{subpart-id}}"></div>
|
||||
<div class="w-ba-banner__caption banner-pager banner_caption_{{subpart-id}}" data-list="images" data-level="0">
|
||||
<li><button title="Slide {{slide_number}}"><span style="display: none;">Slide {{slide_number}}</span></button></li>
|
||||
</div>
|
||||
<ul class="controlplay"><a class="resume-slide active" title = "<%= (I18n.locale.to_s =="zh_tw") ? "繼續播放" : "resume" %>"><i></i></a><a class="pause-slide" title = "<%= (I18n.locale.to_s =="zh_tw") ? "暫停播放" : "pause"%>"><i></i></a></ul>
|
||||
<ul class="button-mid">
|
||||
<i class="fa fa-angle-left prev-button" aria-hidden="true" title = "<%= (I18n.locale.to_s =="zh_tw") ? "上一張" : "prev" %>"></i>
|
||||
<i class="fa fa-angle-right next-button" aria-hidden="true" title = "<%= (I18n.locale.to_s =="zh_tw") ? "下一張" : "next" %>"></i>
|
||||
</ul>
|
||||
</div>
|
||||
<script>
|
||||
var flag = 1;
|
||||
$('.pause-slide').off('click').click(function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle('pause');
|
||||
$(this).addClass('active')
|
||||
$(this).parents('.controlplay').eq(0).find('.resume-slide').removeClass('active')
|
||||
});
|
||||
$('.resume-slide').off('click').click(function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle('resume');
|
||||
$(this).addClass('active')
|
||||
$(this).parents('.controlplay').eq(0).find('.pause-slide').removeClass('active')
|
||||
});
|
||||
$('.next-button').off('click').on('click',function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle("next");
|
||||
|
||||
})
|
||||
$('.prev-button').off('click').on('click',function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle("prev");
|
||||
})
|
||||
|
||||
</script>
|
||||
<style type="text/css">
|
||||
.controlplay .resume-slide.active i{
|
||||
color: #32D9C3;
|
||||
}
|
||||
.controlplay .pause-slide.active i{
|
||||
color: #ff4500;
|
||||
}
|
||||
</style>
|
|
@ -1,70 +0,0 @@
|
|||
<div class="w-ba-banner ad-banner-widget-6 ba-banner-widget-6">
|
||||
<div class="w-ba-banner__wrap cycle-slideshow"
|
||||
data-list="images"
|
||||
data-level="0"
|
||||
data-cycle-slides=".w-ba-banner__slide"
|
||||
data-cycle-log="false"
|
||||
data-overlay=".w-ad-banner__overlay_{{subpart-id}}"
|
||||
data-cycle-auto-height="{{base_image}}"
|
||||
data-cycle-speed="{{speed}}"
|
||||
data-cycle-timeout="{{timeout}}"
|
||||
data-cycle-fx="{{ad_fx}}"
|
||||
data-cycle-pager=".banner_caption_{{subpart-id}}"
|
||||
data-pager-template=""
|
||||
data-pager-active-class="active-slide"
|
||||
data-cycle-swipe=true
|
||||
data-cycle-swipe-fx="scrollHorz"
|
||||
>
|
||||
<div class="w-ba-banner__slide {{class}}"
|
||||
data-link="{{link}}"
|
||||
data-cycle-title="{{title}}"
|
||||
data-cycle-desc="{{context}}"
|
||||
data-overlay-template="<h3>{{title}}</h3><p>{{desc}}</p>"
|
||||
data-target="{{target}}"
|
||||
>
|
||||
<a href="{{link}}" target="{{target}}" title="{{alt_title}}">
|
||||
<img class="w-ba-banner__image banner-responsive" src="{{image_link}}" alt="{{alt_title}}">
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="ad-overlay w-ba-banner__caption w-ad-banner__caption w-ad-banner__overlay_{{subpart-id}}"></div>
|
||||
<div class="w-ba-banner__caption banner-pager banner_caption_{{subpart-id}}" data-list="images" data-level="0">
|
||||
<li><button title="Slide {{slide_number}}"><span style="display: none;">Slide {{slide_number}}</span></button></li>
|
||||
</div>
|
||||
<ul class="controlplay"><a class="resume-slide active" title = "<%= (I18n.locale.to_s =="zh_tw") ? "繼續播放" : "resume" %>"><i></i></a><a class="pause-slide" title = "<%= (I18n.locale.to_s =="zh_tw") ? "暫停播放" : "pause"%>"><i></i></a></ul>
|
||||
<ul class="button-mid">
|
||||
<i class="fa fa-angle-left prev-button" aria-hidden="true" title = "<%= (I18n.locale.to_s =="zh_tw") ? "上一張" : "prev" %>"></i>
|
||||
<i class="fa fa-angle-right next-button" aria-hidden="true" title = "<%= (I18n.locale.to_s =="zh_tw") ? "下一張" : "next" %>"></i>
|
||||
</ul>
|
||||
<div class="background-overlay"></div>
|
||||
</div>
|
||||
<script>
|
||||
var flag = 1;
|
||||
$('.pause-slide').off('click').click(function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle('pause');
|
||||
$(this).addClass('active')
|
||||
$(this).parents('.controlplay').eq(0).find('.resume-slide').removeClass('active')
|
||||
});
|
||||
$('.resume-slide').off('click').click(function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle('resume');
|
||||
$(this).addClass('active')
|
||||
$(this).parents('.controlplay').eq(0).find('.pause-slide').removeClass('active')
|
||||
});
|
||||
$('.next-button').off('click').on('click',function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle("next");
|
||||
|
||||
})
|
||||
$('.prev-button').off('click').on('click',function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle("prev");
|
||||
})
|
||||
|
||||
</script>
|
||||
<style type="text/css">
|
||||
.controlplay .resume-slide.active i{
|
||||
color: #32D9C3;
|
||||
}
|
||||
.controlplay .pause-slide.active i{
|
||||
color: #ff4500;
|
||||
}
|
||||
</style>
|
|
@ -19,7 +19,7 @@
|
|||
data-link="{{link}}"
|
||||
data-cycle-title="{{title}}"
|
||||
data-cycle-desc="{{context}}"
|
||||
data-overlay-template="<h3>{{title}}</h3><p>{{desc}}</p>"
|
||||
data-overlay-template="<a href='{{link}}' target='{{target}}' title='{{alt_title}}'><h3>{{title}}</h3><p>{{desc}}</p></a>"
|
||||
data-target="{{target}}"
|
||||
>
|
||||
<a href="{{link}}" target="{{target}}" title="{{alt_title}}">
|
||||
|
|
|
@ -128,7 +128,7 @@
|
|||
num=1;
|
||||
}
|
||||
var flag=false;
|
||||
$('.btn-left').click(function(){
|
||||
$('[data-subpart-id=\"{{subpart-id}}\"] .btn-left').click(function(){
|
||||
if(!flag){
|
||||
var uls = $('[data-subpart-id=\"{{subpart-id}}\"] ul.w-annc__list:not(.hidden_item)').toArray();
|
||||
var ul_length = uls.length;
|
||||
|
@ -147,7 +147,7 @@
|
|||
$('[data-subpart-id=\"{{subpart-id}}\"] ul.w-annc__list.active').eq(0).effect("slide", { direction: "left", mode: 'show', duration: 500},function(){$("body").css("overflow-x","");flag=false;});
|
||||
};
|
||||
});
|
||||
$('.btn-right').click(function(){
|
||||
$('[data-subpart-id=\"{{subpart-id}}\"] .btn-right').click(function(){
|
||||
var lilength = $('[data-subpart-id=\"{{subpart-id}}\"] li.w-annc__item').length;
|
||||
if(!flag){
|
||||
var uls = $('[data-subpart-id=\"{{subpart-id}}\"] ul.w-annc__list:not(.hidden_item)').toArray();
|
||||
|
|
|
@ -3,35 +3,29 @@
|
|||
<li>{{content}}</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
(function(){
|
||||
var main_div = $("div[data-subpart-id={{subpart-id}}]"),
|
||||
total_texts = main_div.find("ul li").length - 1,
|
||||
current_text = 0,
|
||||
last_text = 0;
|
||||
|
||||
last_text = 0,
|
||||
speed = 3000;
|
||||
main_div.find("ul li").hide();
|
||||
var textTransform = function(){
|
||||
current_text++;
|
||||
function textTransform(){
|
||||
current_text = (current_text > total_texts ? 0 : current_text);
|
||||
last_text = (current_text == 0 ? total_texts : current_text - 1);
|
||||
speed = $('.marquee > li > a').eq(current_text).attr('speed');
|
||||
main_div.find("ul li").eq(last_text).slideUp(500);
|
||||
main_div.find("ul li").eq(current_text).slideDown(500);
|
||||
speed = main_div.find("ul li").eq(current_text).find("> a").eq(0).attr('speed');
|
||||
main_div.find("ul li").eq(last_text).stop(true, true).slideUp({duration: 500, queue: true});
|
||||
main_div.find("ul li").eq(current_text).stop(true, true).slideDown({duration: 500, queue: true});
|
||||
current_text++;
|
||||
if(total_texts > 0){
|
||||
setTimeout(textTransform,speed);
|
||||
if(window["{{subpart-id}}_time_out_id"])
|
||||
clearTimeout(window["{{subpart-id}}_time_out_id"]);
|
||||
window["{{subpart-id}}_time_out_id"] = setTimeout(textTransform,speed);
|
||||
}
|
||||
return;
|
||||
}
|
||||
setTimeout(textTransform,500);
|
||||
textTransform();
|
||||
})();
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
(function(){
|
||||
var main_div = $("div[data-subpart-id"{{subpart-id}})
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"widgets" : [
|
||||
{
|
||||
"filename" : "widget",
|
||||
"name" : {
|
||||
"zh_tw" : "跑馬燈",
|
||||
"en" : "marquee"
|
||||
},
|
||||
"thumbnail" : "thumb.png"
|
||||
}
|
||||
]
|
||||
{
|
||||
"widgets" : [
|
||||
{
|
||||
"filename" : "widget",
|
||||
"name" : {
|
||||
"zh_tw" : "跑馬燈",
|
||||
"en" : "marquee"
|
||||
},
|
||||
"thumbnail" : "thumb.png"
|
||||
}
|
||||
]
|
||||
}
|
|
@ -12,7 +12,7 @@
|
|||
<%= javascript_include_tag "plugin/picturefill.min.js"%>
|
||||
<%= javascript_include_tag "plugin/jquery.mobile.custom.min.js"%>
|
||||
<%= javascript_include_tag "bootstrap.min"%>
|
||||
<%= javascript_include_tag "bootstrap.min"%>
|
||||
|
||||
|
||||
<%= javascript_include_tag "plugin/jquery.cycle2.video.min.js"%>
|
||||
<%= javascript_include_tag "plugin/jquery-bullseye-min.js"%>
|
||||
|
|
Loading…
Reference in New Issue