update template
This commit is contained in:
parent
5c3e0173e4
commit
28ab3156cb
|
@ -303,6 +303,8 @@
|
|||
@mixin gradient-horizontal($start-color: #555, $end-color: #333, $start-percent: 0%, $end-percent: 100%) {
|
||||
background-image: -webkit-linear-gradient(left, color-stop($start-color $start-percent), color-stop($end-color $end-percent)); // Safari 5.1-6, Chrome 10+
|
||||
background-image: linear-gradient(to right, $start-color $start-percent, $end-color $end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
|
||||
-pie-background: linear-gradient(to right, $start-color $start-percent, $end-color $end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=1); // IE9 and down
|
||||
}
|
||||
|
@ -314,6 +316,8 @@
|
|||
@mixin gradient-vertical($start-color: #555, $end-color: #333, $start-percent: 0%, $end-percent: 100%) {
|
||||
background-image: -webkit-linear-gradient(top, $start-color $start-percent, $end-color $end-percent); // Safari 5.1-6, Chrome 10+
|
||||
background-image: linear-gradient(to bottom, $start-color $start-percent, $end-color $end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
|
||||
-pie-background: linear-gradient(to bottom, $start-color $start-percent, $end-color $end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=0); // IE9 and down
|
||||
}
|
||||
|
@ -322,16 +326,22 @@
|
|||
background-repeat: repeat-x;
|
||||
background-image: -webkit-linear-gradient($deg, $start-color, $end-color); // Safari 5.1-6, Chrome 10+
|
||||
background-image: linear-gradient($deg, $start-color, $end-color); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
|
||||
-pie-background: linear-gradient($deg, $start-color, $end-color); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
}
|
||||
@mixin gradient-horizontal-three-colors($start-color: #00b3ee, $mid-color: #7a43b6, $color-stop: 50%, $end-color: #c3325f) {
|
||||
background-image: -webkit-linear-gradient(left, $start-color, $mid-color $color-stop, $end-color);
|
||||
background-image: linear-gradient(to right, $start-color, $mid-color $color-stop, $end-color);
|
||||
-pie-background: linear-gradient(to right, $start-color, $mid-color $color-stop, $end-color);
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
background-repeat: no-repeat;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=1); // IE9 and down, gets no color-stop at all for proper fallback
|
||||
}
|
||||
@mixin gradient-vertical-three-colors($start-color: #00b3ee, $mid-color: #7a43b6, $color-stop: 50%, $end-color: #c3325f) {
|
||||
background-image: -webkit-linear-gradient($start-color, $mid-color $color-stop, $end-color);
|
||||
background-image: linear-gradient($start-color, $mid-color $color-stop, $end-color);
|
||||
-pie-background: linear-gradient($start-color, $mid-color $color-stop, $end-color);
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
background-repeat: no-repeat;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=0); // IE9 and down, gets no color-stop at all for proper fallback
|
||||
}
|
||||
|
@ -343,6 +353,8 @@
|
|||
@mixin gradient-striped($color: rgba(255,255,255,.15), $angle: 45deg) {
|
||||
background-image: -webkit-linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent);
|
||||
background-image: linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent);
|
||||
-pie-background: linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent);
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
}
|
||||
|
||||
// Reset filters for IE
|
||||
|
|
|
@ -37,6 +37,8 @@
|
|||
width: 100%;
|
||||
bottom: 0;
|
||||
background-image: linear-gradient(180deg,transparent 0,rgba(0,0,0,.7) 40%,#000);
|
||||
-pie-background: linear-gradient(180deg,transparent 0,rgba(0,0,0,.7) 40%,#000);
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
padding: 1.5em 1em;
|
||||
h3 {
|
||||
margin: 0;
|
||||
|
@ -85,6 +87,7 @@
|
|||
width: 0.8em;
|
||||
height: 0.8em;
|
||||
border-radius: 50%;
|
||||
behavior: url("/assets/ie_support/PIE2/PIE.htc");
|
||||
opacity: .5;
|
||||
cursor:pointer;
|
||||
border:0;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<table class="table table-hover table-striped active-index">
|
||||
<caption>
|
||||
<h1>{{page-title}}</h1>
|
||||
<h3>{{page-title}}</h3>
|
||||
</caption>
|
||||
<thead>
|
||||
<tr>
|
||||
|
@ -14,10 +14,15 @@
|
|||
<tbody data-level="0" data-list="acts">
|
||||
<tr>
|
||||
<td>{{category}}</td>
|
||||
<td>{{act_start_date}} ~ <br /> {{act_end_date}}</td>
|
||||
<td>{{title}}</td>
|
||||
<td>{{sign_start_date}} ~ <br /> {{sign_end_date}}</td>
|
||||
<td>{{sign_up}}</i></td>
|
||||
<td>{{act_duration_date}}</td>
|
||||
<td>
|
||||
<span class="active-status-wrap" data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
</span>
|
||||
{{title}}
|
||||
</td>
|
||||
<td>{{sign_duration_date}}</td>
|
||||
<td>{{sign_up}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
<div class="active-index1 {{display}}">
|
||||
<h3>{{page-title}}</h3>
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="active-th-time">{{th_act_time_range}}</th>
|
||||
<th class="active-th-title">{{th_title}}</th>
|
||||
<th class="col-md-2">{{th_sign_up}}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody data-level="0" data-list="acts">
|
||||
<tr>
|
||||
<td class="active-time" date-format="%Y-%m-%d">{{act_duration_date}}</td>
|
||||
<td class="active-content">
|
||||
<span class="active-status-wrap" data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
</span>
|
||||
{{title}}
|
||||
</td>
|
||||
<td>{{sign_up}}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{{pagination_goes_here}}
|
|
@ -0,0 +1,32 @@
|
|||
<div class="active-index2">
|
||||
<h3>{{page-title}}</h3>
|
||||
<ul class="row" data-level="0" data-list="acts">
|
||||
<li class="col-md-4">
|
||||
<a href="{{link_to_show}}">
|
||||
<div class="active-img-wrap">
|
||||
<img src="{{img_src}}" alt="{{img_description}}" title="{{img_description}}">
|
||||
</div>
|
||||
<div class="active-content-wrap">
|
||||
<div class="active-meta">
|
||||
<span class="active-status-wrap" data-list="statuses" data-level="1">
|
||||
<span class="label {{status-class}}">{{status}}</span>
|
||||
</span>
|
||||
<span class="active-time-wrap" date-format="%Y-%m-%d">
|
||||
<i class="fa fa-calendar-o"></i>
|
||||
<span class="active-time" date-format="%Y-%m-%d">{{act_duration_date}}</span>
|
||||
</span>
|
||||
<span class="active-category-wrap">
|
||||
<i class="fa fa-tasks"></i>
|
||||
<span class="active-category">{{category}}</span>
|
||||
</span>
|
||||
</div>
|
||||
<h4 class="active-title">
|
||||
{{title_text}}
|
||||
</h4>
|
||||
<p class="active-subtitle">{{subtitle}}</p>
|
||||
</div>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
{{pagination_goes_here}}
|
|
@ -3,10 +3,26 @@
|
|||
{
|
||||
"filename" : "active_index",
|
||||
"name" : {
|
||||
"zh_tw" : "1. 列表",
|
||||
"en" : "1. List"
|
||||
},
|
||||
"zh_tw" : "1. 列表 (類別, 活動期間, 狀態, 活動標題, 報名期間, 線上報名)",
|
||||
"en" : "1. List (Category, Event Period, status, Event Title, Registration Period, Register)"
|
||||
},
|
||||
"thumbnail" : "thumb.png"
|
||||
},
|
||||
{
|
||||
"filename" : "active_index1",
|
||||
"name" : {
|
||||
"zh_tw" : "2. 精簡表格列表-2 ( 模組標題, 活動期間, 狀態, 標題, 線上報名)",
|
||||
"en" : "2. Simple Table List (widget-title, Event Period, status, title, Register)"
|
||||
},
|
||||
"thumbnail" : "active_index1_thumbs.png"
|
||||
},
|
||||
{
|
||||
"filename" : "active_index2",
|
||||
"name" : {
|
||||
"zh_tw" : "3. 三欄圖文 ( 模組標題, 圖片, 狀態, 活動期間, 類別, 標題, 副標題, 線上報名)",
|
||||
"en" : "3. 3-Column Standard Image + Text (widget-title, image, status, postdate, category, title, subtitle, Register)"
|
||||
},
|
||||
"thumbnail" : "active_index2_thumbs.png"
|
||||
}
|
||||
]
|
||||
}
|
Binary file not shown.
After Width: | Height: | Size: 2.1 KiB |
Binary file not shown.
After Width: | Height: | Size: 3.3 KiB |
|
@ -1,5 +1,5 @@
|
|||
<div class="w-ba-banner ad-banner-widget-1 ba-banner-widget-1">
|
||||
<div class="w-ba-banner__wrap cycle-slideshow"
|
||||
<div class="w-ad-banner w-ba-banner ad-banner-widget-1 ba-banner-widget-1">
|
||||
<div class="w-ad-banner__wrap w-ba-banner__wrap cycle-slideshow"
|
||||
data-list="images"
|
||||
data-level="0"
|
||||
data-cycle-slides=".w-ba-banner__slide"
|
||||
|
@ -15,7 +15,7 @@
|
|||
data-cycle-swipe=true
|
||||
data-cycle-swipe-fx="scrollHorz"
|
||||
>
|
||||
<div class="w-ba-banner__slide {{class}}"
|
||||
<div class="w-ad-banner__slide w-ba-banner__slide {{class}}"
|
||||
data-link="{{link}}"
|
||||
data-cycle-title="{{title}}"
|
||||
data-cycle-desc="{{context}}"
|
||||
|
@ -23,13 +23,13 @@
|
|||
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}}">
|
||||
<img class="w-ad-banner__image 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">
|
||||
<div class="w-ad-banner__caption ad-overlay w-ba-banner__caption w-ad-banner__caption w-ad-banner__overlay_{{subpart-id}}"></div>
|
||||
<div class="w-ad-banner__pager-1 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>
|
||||
|
@ -60,10 +60,23 @@
|
|||
|
||||
</script>
|
||||
<style type="text/css">
|
||||
.controlplay .resume-slide.active i{
|
||||
.w-ba-banner .controlplay .resume-slide.active i{
|
||||
color: #32D9C3;
|
||||
}
|
||||
.controlplay .pause-slide.active i{
|
||||
.w-ba-banner .controlplay .pause-slide.active i{
|
||||
color: #ff4500;
|
||||
}
|
||||
.w-ba-banner .controlplay{
|
||||
width: auto;
|
||||
}
|
||||
.w-ba-banner .button-mid{
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
.next-button,.prev-button{
|
||||
cursor: pointer;
|
||||
}
|
||||
</style>
|
|
@ -1,5 +1,5 @@
|
|||
<div class="w-ba-banner ba-banner-widget-1 ba-banner-widget-youtube">
|
||||
<div class="w-ba-banner__wrap cycle-slideshow"
|
||||
<div class="w-ad-banner ad-banner-widget-2 w-ba-banner ba-banner-widget-1 ba-banner-widget-youtube">
|
||||
<div class="w-ad-banner__wrap w-ba-banner__wrap cycle-slideshow"
|
||||
data-list="images"
|
||||
data-level="0"
|
||||
data-cycle-slides=".w-ba-banner__slide"
|
||||
|
@ -25,7 +25,7 @@
|
|||
{{html}}
|
||||
</div>
|
||||
<div class="ad-overlay w-ad-banner__overlay_{{subpart-id}}"></div>
|
||||
<div class="w-ba-banner__caption banner-pager banner_caption_{{subpart-id}}"></div>
|
||||
<div class="w-ba-banner__caption w-ad-banner__pager-2 banner-pager banner_caption_{{subpart-id}}"></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>
|
||||
|
@ -45,53 +45,116 @@
|
|||
var firstScriptTag = document.getElementsByTagName('script')[0];
|
||||
firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);
|
||||
}
|
||||
|
||||
$("document").ready(function(){
|
||||
$("*[data-yt-binded=0]").each(function(){
|
||||
$(this).attr("data-yt-binded","1");
|
||||
var obj = $(this).find("iframe");
|
||||
obj.attr("id",$(this).data("youtube-id") + "_" + ad_banners_count);
|
||||
ad_banners_count++;
|
||||
})
|
||||
});
|
||||
|
||||
$("*[data-yt-binded=0]").each(function(){
|
||||
$(this).attr("data-yt-binded","1");
|
||||
var obj = $(this).find("iframe");
|
||||
obj.attr("id",$(this).data("youtube-id") + "_" + ad_banners_count);
|
||||
ad_banners_count++;
|
||||
})
|
||||
if (typeof onYouTubeIframeAPIReady !== 'function'){
|
||||
if(window.yt_players == undefined)
|
||||
window.yt_players = {};
|
||||
$(".w-ba-banner__wrap[data-overlay=\".w-ad-banner__overlay_{{subpart-id}}\"]");
|
||||
function onYouTubeIframeAPIReady(){
|
||||
$(".w-ba-banner iframe[data-yt-api-binded=0]").each(function(){
|
||||
$(this).attr("data-yt-api-binded","1");
|
||||
new YT.Player($(this).attr("id"), {
|
||||
events: {
|
||||
'onStateChange': onPlayerStateChange
|
||||
}
|
||||
});
|
||||
$(".w-ba-banner").each(function(i,banner){
|
||||
var iframes = $(banner).find("iframe");
|
||||
if(iframes.length > 0){
|
||||
var id = $(banner).attr("data-subpart-id");
|
||||
if(yt_players[id] == undefined)
|
||||
yt_players[id] = {};
|
||||
var remove_ids = [];
|
||||
Object.keys(yt_players[id]).forEach(function(k){
|
||||
var yt_player = yt_players[id][k];
|
||||
if($(yt_player.getIframe()).length == 0){
|
||||
yt_player.destroy();
|
||||
remove_ids.push(k);
|
||||
}
|
||||
})
|
||||
remove_ids.forEach(function(k){
|
||||
delete yt_players[id][k];
|
||||
})
|
||||
iframes.each(function(i,iframe){
|
||||
console.log($(iframe).attr("id"))
|
||||
var yt_player = yt_players[id][$(iframe).attr("id")];
|
||||
if(yt_player){
|
||||
}else{
|
||||
yt_player = new YT.Player($(iframe).attr("id"), {
|
||||
events: {
|
||||
'onReady': function(event){
|
||||
var height = $(event.target.getIframe()).height();
|
||||
var banner_wrap = $(".w-ba-banner__wrap[data-overlay=\".w-ad-banner__overlay_{{subpart-id}}\"]");
|
||||
banner_wrap.height(height).css({"padding-bottom":"4em","padding-top":""});
|
||||
banner_wrap.find(".cycle-carousel-wrap").css("top","3em");
|
||||
delete event.target.B.onStateChange;
|
||||
var onStateChange_idx = event.target.l.i.onStateChange;
|
||||
onStateChange_idx.reverse();
|
||||
var event_size = 3;
|
||||
onStateChange_idx.forEach(function(start_idx){
|
||||
event.target.l.h.splice(start_idx,event_size);
|
||||
});
|
||||
event.target.l.i.onStateChange = [];
|
||||
event.target.l.s = event.target.l.h.length;
|
||||
event.target.addEventListener('onStateChange',onPlayerStateChange);
|
||||
{{extra_ready_script}}
|
||||
},
|
||||
'onStateChange': onPlayerStateChange
|
||||
}
|
||||
});
|
||||
yt_players[id][$(iframe).attr("id")] = yt_player;
|
||||
$(iframe).data("yt_player",yt_player);
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function onPlayerStateChange(event){
|
||||
var iframe = $(event.target.h),
|
||||
cyclediv = iframe.parents("div.cycle-slideshow");
|
||||
var widget = cyclediv.parents('.ba-banner-widget-youtube')
|
||||
var widget = cyclediv.parents('.ba-banner-widget-youtube');
|
||||
if(event.data == YT.PlayerState.PLAYING || event.data == YT.PlayerState.BUFFERING){
|
||||
cyclediv[0].need_resume = !(cyclediv.hasClass("cycle-paused"));
|
||||
cyclediv.cycle("pause");
|
||||
widget.find('.banner-pager,.controlplay,.button-mid,.ad-overlay').css('visibility','hidden')
|
||||
}else if(event.data == YT.PlayerState.PAUSED || event.data == YT.PlayerState.ENDED){
|
||||
cyclediv.cycle("resume");
|
||||
}else if(event.data == YT.PlayerState.UNSTARTED || event.data == YT.PlayerState.PAUSED || event.data == YT.PlayerState.ENDED){
|
||||
if(cyclediv[0].need_resume)
|
||||
cyclediv.cycle("resume");
|
||||
widget.find('.banner-pager,.controlplay,.button-mid,.ad-overlay').css('visibility','')
|
||||
}
|
||||
{{extra_state_chnage_script}}
|
||||
}
|
||||
$(document).ready(function(){
|
||||
window.onYouTubePlayerAPIReady = function() {
|
||||
onYouTubeIframeAPIReady();
|
||||
onYouTubeIframeAPIReady.apply(this,arguments);
|
||||
};
|
||||
var banner_wrap = $(".w-ba-banner__wrap[data-overlay=\".w-ad-banner__overlay_{{subpart-id}}\"]");
|
||||
var opts = banner_wrap.data('cycle.opts');
|
||||
banner_wrap.on('cycle-paused',function(opts){
|
||||
var controlplay = $(this).nextAll(".controlplay");
|
||||
if(controlplay.length != 0){
|
||||
controlplay.find(".resume-slide").removeClass("active");
|
||||
controlplay.find(".pause-slide").addClass("active");
|
||||
}
|
||||
})
|
||||
banner_wrap.on('cycle-resumed',function(opts){
|
||||
var controlplay = $(this).nextAll(".controlplay");
|
||||
if(controlplay.length != 0){
|
||||
controlplay.find(".resume-slide").addClass("active");
|
||||
controlplay.find(".pause-slide").removeClass("active");
|
||||
}
|
||||
})
|
||||
var height = opts.slides.filter('.active').height() || opts.slides.height();
|
||||
banner_wrap.height(height).css("padding-bottom","");
|
||||
{{extra_document_ready_script}}
|
||||
$('.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')
|
||||
$(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')
|
||||
$(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");
|
||||
|
@ -99,14 +162,39 @@ if (typeof onYouTubeIframeAPIReady !== 'function'){
|
|||
$('.prev-button').off('click').on('click',function(){
|
||||
$(this).parent("ul").parent('.w-ba-banner').find(".cycle-slideshow").cycle("prev");
|
||||
})
|
||||
var resize_timeout_id;
|
||||
$(window).resize(function(){
|
||||
if(resize_timeout_id){
|
||||
window.clearTimeout(resize_timeout_id);
|
||||
}
|
||||
resize_timeout_id = window.setTimeout(function(){
|
||||
var banner_wrap = $(".w-ba-banner__wrap[data-overlay=\".w-ad-banner__overlay_{{subpart-id}}\"]");
|
||||
var opts = banner_wrap.data('cycle.opts');
|
||||
var height = opts.slides.filter('.active').height() || opts.slides.height();
|
||||
banner_wrap.height(height).css("padding-bottom","");
|
||||
},300);
|
||||
})
|
||||
})
|
||||
}
|
||||
</script>
|
||||
<style type="text/css">
|
||||
.controlplay .resume-slide.active i{
|
||||
.w-ba-banner .controlplay .resume-slide.active i{
|
||||
color: #32D9C3;
|
||||
}
|
||||
.controlplay .pause-slide.active i{
|
||||
.w-ba-banner .controlplay .pause-slide.active i{
|
||||
color: #ff4500;
|
||||
}
|
||||
.w-ba-banner .controlplay{
|
||||
width: auto;
|
||||
}
|
||||
.w-ba-banner .button-mid{
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
.next-button,.prev-button{
|
||||
cursor: pointer;
|
||||
}
|
||||
</style>
|
|
@ -23,7 +23,7 @@ $( ".selectbox" ).ready(function() {
|
|||
<a id="filter" style="" href="{{url}}">Clear</a>
|
||||
</form>
|
||||
</div>
|
||||
<table class="table table-hover table-striped journal-papers-index">
|
||||
<table class="table table-hover table-striped book-index">
|
||||
<thead>
|
||||
<tr data-level="0" data-list="headers">
|
||||
<th class="col-md-{{col}}">{{head-title}}</th>
|
||||
|
|
|
@ -38,10 +38,15 @@
|
|||
{{pagination_goes_here}}
|
||||
|
||||
<script>
|
||||
$('table.college_projects-index').DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false
|
||||
});
|
||||
$('table.college_projects-index').each(function(){
|
||||
if($(this).find('thead').length!=0 && $(this).find('td').length!=0 && !$(this).hasClass('dataTable')){
|
||||
$(this).DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false,
|
||||
autoWidth: false
|
||||
});
|
||||
}
|
||||
});;
|
||||
</script>
|
|
@ -63,10 +63,15 @@ $( ".selectbox" ).ready(function() {
|
|||
{{pagination_goes_here}}
|
||||
|
||||
<script>
|
||||
$('table.college_projects-index').DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false
|
||||
});
|
||||
$('table.college_projects-index').each(function(){
|
||||
if($(this).find('thead').length!=0 && $(this).find('td').length!=0 && !$(this).hasClass('dataTable')){
|
||||
$(this).DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false,
|
||||
autoWidth: false
|
||||
});
|
||||
}
|
||||
});;
|
||||
</script>
|
|
@ -23,7 +23,7 @@ $( ".selectbox" ).ready(function() {
|
|||
<a id="filter" style="" href="{{url}}">Clear</a>
|
||||
</form>
|
||||
</div>
|
||||
<table class="table table-hover table-striped projects-index">
|
||||
<table class="table table-hover table-striped personal_conference-index">
|
||||
<thead>
|
||||
<tr data-level="0" data-list="headers">
|
||||
<th class="col-md-{{col}}">{{head-title}}</th>
|
||||
|
|
|
@ -30,10 +30,15 @@
|
|||
{{pagination_goes_here}}
|
||||
|
||||
<script>
|
||||
$('table.create_designs-index').DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false
|
||||
});
|
||||
$('table.create_designs-index').each(function(){
|
||||
if($(this).find('thead').length!=0 && $(this).find('td').length!=0 && !$(this).hasClass('dataTable')){
|
||||
$(this).DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false,
|
||||
autoWidth: false
|
||||
});
|
||||
}
|
||||
});;
|
||||
</script>
|
|
@ -55,10 +55,15 @@ $( ".selectbox" ).ready(function() {
|
|||
{{pagination_goes_here}}
|
||||
|
||||
<script>
|
||||
$('table.create_designs-index').DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false
|
||||
});
|
||||
$('table.create_designs-index').each(function(){
|
||||
if($(this).find('thead').length!=0 && $(this).find('td').length!=0 && !$(this).hasClass('dataTable')){
|
||||
$(this).DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false,
|
||||
autoWidth: false
|
||||
});
|
||||
}
|
||||
});;
|
||||
</script>
|
|
@ -23,7 +23,7 @@ $( ".selectbox" ).ready(function() {
|
|||
<a id="filter" style="" href="{{url}}">Clear</a>
|
||||
</form>
|
||||
</div>
|
||||
<table class="table table-hover table-striped projects-index">
|
||||
<table class="table table-hover table-striped personal_journal-index">
|
||||
<thead>
|
||||
<tr data-level="0" data-list="headers">
|
||||
<th class="col-md-{{col}}">{{head-title}}</th>
|
||||
|
|
|
@ -23,7 +23,7 @@ $( ".selectbox" ).ready(function() {
|
|||
<a id="filter" style="" href="{{url}}">Clear</a>
|
||||
</form>
|
||||
</div>
|
||||
<table class="table table-hover table-striped projects-index">
|
||||
<table class="table table-hover table-striped personal_patent-index">
|
||||
<thead>
|
||||
<tr data-level="0" data-list="headers">
|
||||
<th class="col-md-{{col}}">{{head-title}}</th>
|
||||
|
|
|
@ -34,10 +34,15 @@
|
|||
{{pagination_goes_here}}
|
||||
|
||||
<script>
|
||||
$('table.tec_transfers-index').DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false
|
||||
});
|
||||
$('table.tec_transfers-index').each(function(){
|
||||
if($(this).find('thead').length!=0 && $(this).find('td').length!=0 && !$(this).hasClass('dataTable')){
|
||||
$(this).DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false,
|
||||
autoWidth: false
|
||||
});
|
||||
}
|
||||
});;
|
||||
</script>
|
|
@ -59,10 +59,15 @@ $( ".selectbox" ).ready(function() {
|
|||
{{pagination_goes_here}}
|
||||
|
||||
<script>
|
||||
$('table.tec_transfers-index').DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false
|
||||
});
|
||||
$('table.tec_transfers-index').each(function(){
|
||||
if($(this).find('thead').length!=0 && $(this).find('td').length!=0 && !$(this).hasClass('dataTable')){
|
||||
$(this).DataTable({
|
||||
searching: false,
|
||||
paging: false,
|
||||
ordering: false,
|
||||
info: false,
|
||||
autoWidth: false
|
||||
});
|
||||
}
|
||||
});;
|
||||
</script>
|
|
@ -0,0 +1,57 @@
|
|||
<div id="{{update_id}}" class="bus_widget1" data-list="bus_infos" data-level="0">
|
||||
<div class="bus_info" id="{{bus_id}}">
|
||||
<div class="row mt-10">
|
||||
<div class="col-sm-12 bus_title">
|
||||
<i class="fa fa-bus"></i>
|
||||
<strong>{{bus_title}}</strong>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row bus_data" data-list="bus_data" data-level="1">
|
||||
<div class="col-sm-6">
|
||||
<div>
|
||||
<strong class="route_name">{{route_name}}:</strong>
|
||||
<span class="bus_time">{{time_to_arrive}}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
function update_bus(ele){
|
||||
var $self = $(ele);
|
||||
var bus_info_ids = $.map($self.find('.bus_info'),function(v){
|
||||
return $(v).attr('id');
|
||||
});
|
||||
$.{{update_method}}( "{{update_url}}",
|
||||
{
|
||||
bus_info_ids: bus_info_ids
|
||||
}, function( data ) {
|
||||
$.each(data,function(k,v){
|
||||
var bus_info = $self.find('#'+k);
|
||||
var bus_route_names = $.map(bus_info.find('.route_name'),function(v1){
|
||||
return $(v1).text().slice(0,-1)
|
||||
});
|
||||
var bus_time_span = bus_info.find('.bus_time');
|
||||
$.each(v,function(k,v1){
|
||||
var i = bus_route_names.indexOf(v1.route_name);
|
||||
if (i>=0){
|
||||
bus_time_span.eq(i).html(v1.time_to_arrive);
|
||||
}
|
||||
})
|
||||
})
|
||||
window.setTimeout(function(){
|
||||
update_bus(ele);
|
||||
},{{update_interval}});
|
||||
});
|
||||
}
|
||||
function update_interval_bus(ele) {
|
||||
window.setTimeout(function(){
|
||||
update_bus(ele);
|
||||
},{{update_interval}});
|
||||
}
|
||||
update_interval_bus($('#{{update_id}}[data-list="bus_infos"]')[0]);
|
||||
</script>
|
||||
<style type="text/css">
|
||||
.bus_widget1 {margin-top: 1em;}
|
||||
.bus_info {line-height: 1.8;}
|
||||
</style>
|
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"frontend": [
|
||||
],
|
||||
"widgets" : [
|
||||
{
|
||||
"filename" : "ruling_bus_widget1",
|
||||
"name" : {
|
||||
"zh_tw" : "1. 公車呈現樣式1",
|
||||
"en" : "1. Bus layout 1"
|
||||
},
|
||||
"thumbnail" : "bus1_thumbs.png"
|
||||
}
|
||||
]
|
||||
}
|
|
@ -4,6 +4,9 @@
|
|||
</h3>
|
||||
<ul class="list-unstyled" data-level="0" data-list="web_link">
|
||||
<li class="widget-content">
|
||||
<div class="link-img-wrap{{display_image}}">
|
||||
<img src="{{img_src}}" alt="{{img_description}}" title="{{img_description}}">
|
||||
</div>
|
||||
<a class="widget-content-title" href="{{link_to_show}}" target="_blank" title="{{title_text}}">{{title}}</a>
|
||||
<span data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
|
|
|
@ -4,6 +4,9 @@
|
|||
</h3>
|
||||
<ul class="list-unstyled" data-level="0" data-list="web_link">
|
||||
<li class="widget-content widget-content-horizontal">
|
||||
<div class="link-img-wrap{{display_image}}">
|
||||
<img src="{{img_src}}" alt="{{img_description}}" title="{{img_description}}">
|
||||
</div>
|
||||
<a class="widget-content-title" href="{{link_to_show}}" target="_blank" title="{{title_text}}">{{title}}</a>
|
||||
<span data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
|
|
|
@ -4,13 +4,18 @@
|
|||
</h1>
|
||||
<ul class="list-unstyled" data-list="web_link" data-level="0">
|
||||
<li class="index-content">
|
||||
<h4>
|
||||
<a class="index-content-title" href="{{link_to_show}}" target="_blank" title="{{title_text}}">{{title}}</a>
|
||||
<span data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
</span>
|
||||
</h4>
|
||||
<small class="index-context">{{context}}</small>
|
||||
<a class="index-content-title" href="{{link_to_show}}" target="_blank" title="{{title_text}}">
|
||||
<h4>
|
||||
<div class="link-img-wrap{{display_image}}">
|
||||
<img src="{{img_src}}" alt="{{img_description}}" title="{{img_description}}">
|
||||
</div>
|
||||
{{title}}
|
||||
<span data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
</span>
|
||||
</h4>
|
||||
<small class="index-context">{{context}}</small>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
@ -4,13 +4,20 @@
|
|||
</h1>
|
||||
<ul class="list-unstyled" data-list="web_link" data-level="0">
|
||||
<li class="index-content col-md-4 col-sm-4">
|
||||
<h4>
|
||||
<a class="index-content-title" href="{{link_to_show}}" target="_blank" title="{{title_text}}">{{title}}</a>
|
||||
<span data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
</span>
|
||||
</h4>
|
||||
<small class="index-context">{{context}}</small>
|
||||
<a class="index-content-title" href="{{link_to_show}}" target="_blank" title="{{title_text}}">
|
||||
<div class="link-img-wrap{{display_image}}">
|
||||
<img src="{{img_src}}" alt="{{img_description}}" title="{{img_description}}">
|
||||
</div>
|
||||
<h4>
|
||||
<span class="link-title">
|
||||
{{title}}
|
||||
</span>
|
||||
<span data-list="statuses" data-level="1">
|
||||
<span class="label status {{status-class}}">{{status}}</span>
|
||||
</span>
|
||||
</h4>
|
||||
<small class="index-context">{{context}}</small>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
<%= render 'shared/ie_html5_fix' %>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<%= favicon_link_tag (current_site.favicon.blank? ? 'favicon.ico' : current_site.favicon.url) %>
|
||||
|
@ -8,14 +9,8 @@
|
|||
<link rel="stylesheet" media="print" type="text/css" href="/assets/template/print.css">
|
||||
<%= javascript_include_tag "plugin/modernizr.js"%>
|
||||
<%= javascript_include_tag "plugin/picturefill.min.js"%>
|
||||
<%= javascript_include_tag "jquery.min"%>
|
||||
<%= javascript_include_tag "jquery_prefix"%>
|
||||
<%= javascript_include_tag "plugin/jquery.mobile.custom.min.js"%>
|
||||
<%= javascript_include_tag "bootstrap.min"%>
|
||||
<%= javascript_include_tag "//cdnjs.cloudflare.com/ajax/libs/jquery.cycle2/20140415/jquery.cycle2.min.js"%>
|
||||
<%= javascript_include_tag "//cdnjs.cloudflare.com/ajax/libs/jquery.cycle2/20140415/jquery.cycle2.carousel.min.js"%>
|
||||
<%= javascript_include_tag "//cdnjs.cloudflare.com/ajax/libs/jquery.cycle2/20140415/jquery.cycle2.scrollVert.min.js"%>
|
||||
<%= javascript_include_tag "//cdnjs.cloudflare.com/ajax/libs/jquery.cycle2/20140415/jquery.cycle2.tile.min.js"%>
|
||||
<%= javascript_include_tag "plugin/jquery.cycle2.video.min.js"%>
|
||||
<%= javascript_include_tag "plugin/jquery-bullseye-min.js"%>
|
||||
<%= javascript_include_tag "app"%>
|
||||
|
@ -23,6 +18,5 @@
|
|||
<script src="https://apis.google.com/js/platform.js" async defer></script>
|
||||
<%= render_google_analytics %>
|
||||
<!--[if lt IE 9]>
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv.min.js"></script>
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/respond.js/1.4.2/respond.min.js"></script>
|
||||
<![endif]-->
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<a id="accesskey_sitemenu" accesskey="S" href="/<%= "#{locale.to_s}" %>/accesskey" title="Sitemenu">:::</a>
|
||||
<h3 class="sitemenu-title">{{widget_title}}</h3>
|
||||
<ul data-list="pages" class="sitemenu-list level-1 list-unstyled" data-level="0">
|
||||
<li class="sitemenu-item level-1">
|
||||
<li class="sitemenu-item level-1 {{active_class}}">
|
||||
<a class="sitemenu-link level-1" href="{{url}}" target="{{target}}">{{page_name}}</a>
|
||||
<ul class="sitemenu-list level-2" data-list="children" data-level="1">
|
||||
<li class="sitemenu-item level-2" style="position: relative;">
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<a id="accesskey_sitemenu" accesskey="S" href="/<%= "#{locale.to_s}" %>/accesskey" title="Sitemenu">:::</a>
|
||||
<h3 class="sitemenu-title">{{widget_title}}</h3>
|
||||
<ul data-list="pages" class="sitemenu-list level-1 list-unstyled" data-level="0">
|
||||
<li class="sitemenu-item level-1">
|
||||
<li class="sitemenu-item level-1 {{active_class}}">
|
||||
<a class="sitemenu-link level-1" href="{{url}}" target="{{target}}">{{page_name}}</a>
|
||||
<ul class="sitemenu-list level-2" data-list="children" data-level="1">
|
||||
<li class="sitemenu-item level-2" style="position: relative;">
|
||||
|
|
Loading…
Reference in New Issue