Fix mobile banner, icons, announcement css

This commit is contained in:
chris 2013-01-11 18:34:20 +08:00
parent d00192f018
commit 91d1487a04
5 changed files with 29 additions and 22 deletions

View File

@ -25,8 +25,8 @@ $('#index').live('pageinit',function(){
$(".slideImg").muImageResize({width: $globalW, height: Math.floor($globalW/720*240)});
$(this).find(".newpic img").muImageResize({width: 280, height: 200});
$('.slideshow').cycle({
fx:'scrollLeft',
timeout: 6000,
fx: $effect,
timeout: $timeout
});
$(".newlist").css({
"width" : $(".newitem").outerWidth()*(Math.floor($globalW/$(".newitem").outerWidth()))+30,
@ -37,7 +37,7 @@ $('#index').live('pageinit',function(){
// $('.newlist').swipePlanes();
// }, 1000);
});
$('#news_content').live('pageinit',function(){
$('#announcement_content').live('pageinit',function(){
$(this).find(".newpic img").muImageResize({width: 320, height: 220});
});
var mobileDemo = { 'center': '24.987449, 121.576117', 'zoom': 17 };
@ -113,8 +113,8 @@ $(window).bind("orientationchange", function(){
$(".slideImg").muImageResize({width: $globalW, height: Math.floor($globalW/720*240)});
$('.slideshow').cycle({
fx:'scrollLeft',
timeout: 6000,
fx: $effect,
timeout: $timeout
});
$(".newlist").css({

View File

@ -1,9 +1,12 @@
[data-icons]:before {
font-family: 'entypo';
content: attr(data-icon);
content: attr(data-icons);
speak: none;
font-weight: normal;
-webkit-font-smoothing: antialiased;
font-size: 1.5em;
line-height: .6em;
color: white;
}
@font-face {
font-family: 'entypo';

View File

@ -194,28 +194,25 @@ div[data-role="page"] {
padding: 0 0 20px;
margin-bottom: 0;
}
#news_content .content .newpic {
#announcement_content .content .newpic {
width: 320px;
height: 220px;
margin: 0 auto;
}
#news_content .content .newstitle {
#announcement_content .content .newstitle {
font-size: 1.4em;
padding: 0 10px;
margin: 1em 0;
}
#news_content .content .newsDate {
#announcement_content .content .newsDate {
padding: 0 10px;
font-size: 1em;
color: #8D8D8D;
}
#news_content .content .newsummary {
#announcement_content .content .newsummary {
padding: 0 10px 20px;
margin-bottom: 0;
}
#announcement_content .content {
padding: 10px;
}
#map div[data-role="content"] {
padding: 0;
}

View File

@ -9,12 +9,12 @@
<% end -%>
</div>
<ul class="nav">
<li><a href="<%= root_path %>" data-icon="&#xe022;"></a></li>
<!-- <li><a href="<%= desktop_path %>" data-icon="&#xe060;"></a></li> -->
<li><a href="<%= root_path %>" data-icons="&#xe022;"></a></li>
<!-- <li><a href="<%= desktop_path %>" data-icons="&#xe060;"></a></li> -->
</ul>
<ul class="nav pull-right">
<li class="dropdown">
<a class="dropdown-toggle" data-icon="&#xe02d;" href="#" data-toggle="dropdown"></a>
<a class="dropdown-toggle" data-icons="&#xe02d;" href="#" data-toggle="dropdown"></a>
<ul class="dropdown-menu">
<% t('ntu.site_names').each do |site| %>
<li><%= link_to site[1], get_link(site[0]) %></li>
@ -22,7 +22,7 @@
</ul>
</li>
<li class="dropdown language">
<a class="dropdown-toggle" href="#" data-toggle="dropdown" data-icon="&#xe054;"></a>
<a class="dropdown-toggle" href="#" data-toggle="dropdown" data-icons="&#xe054;"></a>
<ul class="dropdown-menu language-menu">
<% @site_in_use_locales.each do |locale| %>
<%= content_tag :li, (link_to t(:_locale, :locale => locale), add_locale(remove_locale((referer rescue request.fullpath)), locale)), :class => (I18n.locale.eql?(locale.to_sym) ? 'active' : nil) %>
@ -30,7 +30,7 @@
</ul>
</li>
<li class="search clear" title="<%= t :search_google %>">
<a class="orbit-bar-search" href="#" data-icon="&#xe024;"></a>
<a class="orbit-bar-search" href="#" data-icons="&#xe024;"></a>
<form class="navbar-search" method="get" action="http://www.google.com/custom">
<input type="hidden" name="client" value="pub-&amp" />
<input type="hidden" name="ie" id="ie" value="utf-8" />
@ -63,7 +63,7 @@
</li>
<% else %>
<li class="dropdown bar-login">
<a class="dropdown-toggle orbit-bar-member" href="#" data-icon="&#xe076;"></a>
<a class="dropdown-toggle orbit-bar-member" href="#" data-icons="&#xe076;"></a>
<div class="dropdown-menu">
<ul class="log">
<li class="title hide"></li>

View File

@ -1,6 +1,8 @@
<div class="slideshow">
<% @ad_banner.ad_images.each do |image| %>
<div class="slidebanner"><%= image_tag image.file.url, :class => 'slideImg' %></div>
<% @ad_banner.ad_images.shuffle.each do |image| %>
<% if image.display? %>
<div class="slidebanner"><%= image_tag image.file.url, :class => 'slideImg' %></div>
<% end %>
<% end %>
</div>
<div class="newlist clear">
@ -16,4 +18,9 @@
<div class="newsummary"><%= bulletin.subtitle %></div>
</div>
<% end %>
</div>
</div>
<script type='text/javascript'>
var $effect = "<%= @ad_banner.ad_fx.nil? ? 'fade': @ad_banner.ad_fx %>"
var $timeout = "<%= @ad_banner.transition_msec %>"
</script>