From 4c85d62866385d74e60c33b8e1dd9d556c4acb13 Mon Sep 17 00:00:00 2001 From: rulingcom Date: Thu, 12 Dec 2013 15:39:20 +0800 Subject: [PATCH] ray fix for css and filemanager --- app/assets/javascripts/html5.js | 11 +++- app/assets/stylesheets/lib/filemanager.css | 9 +++ app/helpers/application_helper.rb | 6 +- app/views/admin/assets/_edit.html.erb | 8 ++- app/views/admin/assets/_form.html.erb | 64 ++++++++++--------- app/views/admin/assets/index.html.erb | 2 +- app/views/layouts/page_layout.html.erb | 12 ++-- .../bulletins_and_web_links.html.erb | 2 +- .../front_end/archive_files/_index.html.erb | 2 +- .../front_end/archive_files/index.html.erb | 4 +- .../widget/archive_files/index.html.erb | 4 +- .../front_end/ask_questions/index.html.erb | 2 +- .../gallery/front_end/albums/_album.html.erb | 4 +- .../gallery/front_end/albums/index.html.erb | 2 +- .../gallery/front_end/albums/show.html.erb | 2 +- .../gallery/widget/albums/widget1.html.erb | 2 +- .../front_end/member_lists/index.html.erb | 2 +- .../member_staff_lists/index.html.erb | 2 +- .../front_end/channel_videos/index.html.erb | 19 ++++-- .../front_end/web_links/index.html.erb | 2 +- .../widget/web_links/index.html.erb | 2 +- 21 files changed, 94 insertions(+), 69 deletions(-) diff --git a/app/assets/javascripts/html5.js b/app/assets/javascripts/html5.js index 560aa942..448cebd7 100644 --- a/app/assets/javascripts/html5.js +++ b/app/assets/javascripts/html5.js @@ -1,3 +1,8 @@ -/*! HTML5 Shiv vpre3.6 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed - Uncompressed source: https://github.com/aFarkas/html5shiv */ -(function(a,b){function h(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x",d.insertBefore(c.lastChild,d.firstChild)}function i(){var a=l.elements;return typeof a=="string"?a.split(" "):a}function j(a){var b={},c=a.createElement,f=a.createDocumentFragment,g=f();a.createElement=function(a){if(!l.shivMethods)return c(a);var f;return b[a]?f=b[a].cloneNode():e.test(a)?f=(b[a]=c(a)).cloneNode():f=c(a),f.canHaveChildren&&!d.test(a)?g.appendChild(f):f},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+i().join().replace(/\w+/g,function(a){return c(a),g.createElement(a),'c("'+a+'")'})+");return n}")(l,g)}function k(a){var b;return a.documentShived?a:(l.shivCSS&&!f&&(b=!!h(a,"article,aside,details,figcaption,figure,footer,header,hgroup,nav,section{display:block}audio{display:none}canvas,video{display:inline-block;*display:inline;*zoom:1}[hidden]{display:none}audio[controls]{display:inline-block;*display:inline;*zoom:1}mark{background:#FF0;color:#000}")),g||(b=!j(a)),b&&(a.documentShived=b),a)}var c=a.html5||{},d=/^<|^(?:button|form|map|select|textarea|object|iframe|option|optgroup)$/i,e=/^<|^(?:a|b|button|code|div|fieldset|form|h1|h2|h3|h4|h5|h6|i|iframe|img|input|label|li|link|ol|option|p|param|q|script|select|span|strong|style|table|tbody|td|textarea|tfoot|th|thead|tr|ul)$/i,f,g;(function(){var c=b.createElement("a");c.innerHTML="",f="hidden"in c,f&&typeof injectElementWithStyles=="function"&&injectElementWithStyles("#modernizr{}",function(b){b.hidden=!0,f=(a.getComputedStyle?getComputedStyle(b,null):b.currentStyle).display=="none"}),g=c.childNodes.length==1||function(){try{b.createElement("a")}catch(a){return!0}var c=b.createDocumentFragment();return typeof c.cloneNode=="undefined"||typeof c.createDocumentFragment=="undefined"||typeof c.createElement=="undefined"}()})();var l={elements:c.elements||"abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video",shivCSS:c.shivCSS!==!1,shivMethods:c.shivMethods!==!1,type:"default",shivDocument:k};a.html5=l,k(b)})(this,document) \ No newline at end of file +/* + HTML5 Shiv v3.7.0 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed +*/ +(function(l,f){function m(){var a=e.elements;return"string"==typeof a?a.split(" "):a}function i(a){var b=n[a[o]];b||(b={},h++,a[o]=h,n[h]=b);return b}function p(a,b,c){b||(b=f);if(g)return b.createElement(a);c||(c=i(b));b=c.cache[a]?c.cache[a].cloneNode():r.test(a)?(c.cache[a]=c.createElem(a)).cloneNode():c.createElem(a);return b.canHaveChildren&&!s.test(a)?c.frag.appendChild(b):b}function t(a,b){if(!b.cache)b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag(); +a.createElement=function(c){return!e.shivMethods?b.createElem(c):p(c,a,b)};a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+m().join().replace(/[\w\-]+/g,function(a){b.createElem(a);b.frag.createElement(a);return'c("'+a+'")'})+");return n}")(e,b.frag)}function q(a){a||(a=f);var b=i(a);if(e.shivCSS&&!j&&!b.hasCSS){var c,d=a;c=d.createElement("p");d=d.getElementsByTagName("head")[0]||d.documentElement;c.innerHTML="x"; +c=d.insertBefore(c.lastChild,d.firstChild);b.hasCSS=!!c}g||t(a,b);return a}var k=l.html5||{},s=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,r=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,j,o="_html5shiv",h=0,n={},g;(function(){try{var a=f.createElement("a");a.innerHTML="";j="hidden"in a;var b;if(!(b=1==a.childNodes.length)){f.createElement("a");var c=f.createDocumentFragment();b="undefined"==typeof c.cloneNode|| +"undefined"==typeof c.createDocumentFragment||"undefined"==typeof c.createElement}g=b}catch(d){g=j=!0}})();var e={elements:k.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output progress section summary template time video",version:"3.7.0",shivCSS:!1!==k.shivCSS,supportsUnknownElements:g,shivMethods:!1!==k.shivMethods,type:"default",shivDocument:q,createElement:p,createDocumentFragment:function(a,b){a||(a=f); +if(g)return a.createDocumentFragment();for(var b=b||i(a),c=b.frag.cloneNode(),d=0,e=m(),h=e.length;d section { #filemanager .preview-area { margin-bottom: 0; text-align: center; +} +#editform .edit_asset { + margin-bottom: 0; +} +#editform fieldset { + margin-bottom: 0; +} +#editform .input-area .control-label { + width: 160px; } \ No newline at end of file diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 2f41f71d..a3f1bc66 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -191,9 +191,9 @@ module ApplicationHelper def page_stylesheets(page, edit=nil) stylesheets = '' stylesheets << "\n" - stylesheets << "\n" if page.design.css_reset - stylesheets << "\n" - stylesheets << "\n" + # stylesheets << "\n" if page.design.css_reset + # stylesheets << "\n" + # stylesheets << "\n" stylesheets << "\n" if page.design.css_default theme = page.design.themes.detect{ |d| d.id == page.theme_id } stylesheets << "\n" if theme diff --git a/app/views/admin/assets/_edit.html.erb b/app/views/admin/assets/_edit.html.erb index 5924ea1f..9b3e634c 100644 --- a/app/views/admin/assets/_edit.html.erb +++ b/app/views/admin/assets/_edit.html.erb @@ -4,9 +4,11 @@

<%= t('editing.asset') %>

<%= form_for @asset, :url => admin_asset_path(@asset), :remote => true do |f| %> - - + <% content_for :page_specific_javascript do %> <%= javascript_include_tag "file-upload/vendor/jquery.ui.widget.js" %> <%= javascript_include_tag "file-upload/tmpl.min.js" %> diff --git a/app/views/layouts/page_layout.html.erb b/app/views/layouts/page_layout.html.erb index 83e57509..c69c8b31 100644 --- a/app/views/layouts/page_layout.html.erb +++ b/app/views/layouts/page_layout.html.erb @@ -1,20 +1,20 @@ -<%= render 'layouts/meta' %> - + <%= render 'layouts/meta' %> + <%= page_title(@item).html_safe %> - "> + <%= page_metas(@item).html_safe %> - <%= stylesheet_link_tag "page_layout" %> <%= page_stylesheets(@item).html_safe %> <%= javascript_include_tag "page_layout" %> <%= page_javascripts(@item).html_safe %> <%= javascript_include_tag "orbit_js_1.0.1-front-end.js" unless @no_orbit_bar %> <%= csrf_meta_tag %> + <%= yield %> diff --git a/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_and_web_links.html.erb b/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_and_web_links.html.erb index c98e3337..d883c929 100644 --- a/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_and_web_links.html.erb +++ b/vendor/built_in_modules/announcement/app/views/panel/announcement/widget/bulletins/bulletins_and_web_links.html.erb @@ -32,4 +32,4 @@ <% content_for :page_specific_javascript do %> <% end %> -<%= stylesheet_link_tag "announcement/bulletins_and_web_links" %> \ No newline at end of file +<%#= stylesheet_link_tag "announcement/bulletins_and_web_links" %> \ No newline at end of file diff --git a/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/_index.html.erb b/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/_index.html.erb index fe11a15a..149ee2f3 100644 --- a/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/_index.html.erb +++ b/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/_index.html.erb @@ -86,7 +86,7 @@ <% end %> -<%= stylesheet_link_tag "archive/archives" %> +<%#= stylesheet_link_tag "archive/archives" %> diff --git a/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/index.html.erb b/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/index.html.erb index b53d8719..6667866d 100644 --- a/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/index.html.erb +++ b/vendor/built_in_modules/archive/app/views/panel/archive/front_end/archive_files/index.html.erb @@ -1,11 +1,11 @@ -<%= stylesheet_link_tag "default_widget" %> +<%#= stylesheet_link_tag "default_widget" %> <%= javascript_include_tag "mobile/jquery.mu.image.resize.js" %>
<%= render 'index' %>
-<%= stylesheet_link_tag "archive/archives" %> +<%#= stylesheet_link_tag "archive/archives" %> diff --git a/vendor/built_in_modules/archive/app/views/panel/archive/widget/archive_files/index.html.erb b/vendor/built_in_modules/archive/app/views/panel/archive/widget/archive_files/index.html.erb index 26cad128..c01c4637 100644 --- a/vendor/built_in_modules/archive/app/views/panel/archive/widget/archive_files/index.html.erb +++ b/vendor/built_in_modules/archive/app/views/panel/archive/widget/archive_files/index.html.erb @@ -1,8 +1,8 @@ -<%= stylesheet_link_tag "default_widget" %> +<%#= stylesheet_link_tag "default_widget" %> <%= javascript_include_tag "mobile/jquery.mu.image.resize.js" %>
<%= render 'index' %>
-<%= stylesheet_link_tag "archive/archives" %> \ No newline at end of file +<%#= stylesheet_link_tag "archive/archives" %> \ No newline at end of file diff --git a/vendor/built_in_modules/ask/app/views/panel/ask/front_end/ask_questions/index.html.erb b/vendor/built_in_modules/ask/app/views/panel/ask/front_end/ask_questions/index.html.erb index ebd2a1d0..30ea643d 100644 --- a/vendor/built_in_modules/ask/app/views/panel/ask/front_end/ask_questions/index.html.erb +++ b/vendor/built_in_modules/ask/app/views/panel/ask/front_end/ask_questions/index.html.erb @@ -1,4 +1,4 @@ - +