Made use of new ajax loader from Neoteric Design that is now in Refinery core, regenerated gemspec, set up js and css files and currently just reading them in (this will work better under rails3)
This commit is contained in:
parent
aec6ed5a1f
commit
6086ac36ad
6 changed files with 99 additions and 76 deletions
|
@ -76,80 +76,9 @@
|
|||
<% content_for :head do %>
|
||||
<!-- uses famfamfam icons and a couple Dave made -->
|
||||
<style type='text/css'>
|
||||
.comments_icon {
|
||||
background-image: url('/images/refinery/icons/comments.png');
|
||||
}
|
||||
.comment_icon {
|
||||
background-image: url('/images/refinery/icons/comment.png');
|
||||
}
|
||||
.comment_cross_icon {
|
||||
background-image: url('/images/refinery/icons/comment_cross.png');
|
||||
}
|
||||
.comment_tick_icon {
|
||||
background-image: url('/images/refinery/icons/comment_tick.png');
|
||||
}
|
||||
.folder_icon {
|
||||
background-image: url('/images/refinery/icons/folder.png');
|
||||
}
|
||||
.folder_add_icon {
|
||||
background-image: url('/images/refinery/icons/folder_add.png');
|
||||
}
|
||||
.folder_edit_icon {
|
||||
background-image: url('/images/refinery/icons/folder_edit.png');
|
||||
}
|
||||
.settings_icon {
|
||||
background-image: url('/images/refinery/icons/cog.png');
|
||||
}
|
||||
.page_icon {
|
||||
background-image: url('/images/refinery/icons/page.png');
|
||||
}
|
||||
.page_copy_icon {
|
||||
background-image: url('/images/refinery/icons/page_copy.png');
|
||||
}
|
||||
.page_add_icon {
|
||||
background-image: url('/images/refinery/icons/page_add.png');
|
||||
}
|
||||
<%= File.open(File.expand_path('../../../../../public/stylesheets/refinerycms-blog.css', __FILE__), 'r').read %>
|
||||
</style>
|
||||
<script type='text/javascript'>
|
||||
$(document).ready(function(){
|
||||
$('div#actions.multilist > ul:not(.search_list) li a[href$=' + window.location.pathname + ']')
|
||||
.parent().addClass('selected');
|
||||
|
||||
$('div#actions.multilist > ul:not(.search_list) li > a').each(function(i,a){
|
||||
if ($(this).data('dialog-title') == null) {
|
||||
$(this).bind('click', function(){
|
||||
$(this).css('background-image', "url('/images/refinery/ajax-loader.gif') !important");
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$('ul.collapsible_menu').each(function(i, ul) {
|
||||
(first_li = $(this).children('li:first')).after(div=$("<div></div>"));
|
||||
if (($(this).children('li.selected')).length == 0) {
|
||||
div.hide();
|
||||
}
|
||||
$(this).children('li:not(:first)').appendTo(div);
|
||||
|
||||
first_li.find('> a').click(function(e){
|
||||
$(this).parent().next('div').animate({
|
||||
opacity: 'toggle'
|
||||
, height: 'toggle'
|
||||
}, 250, $.proxy(function(){
|
||||
$(this).css('background-image', null);
|
||||
}, $(this))
|
||||
);
|
||||
e.preventDefault();
|
||||
});
|
||||
});
|
||||
|
||||
$('.success_icon, .failure_icon').bind('click', function(e) {
|
||||
$.get($(this).attr('href'), $.proxy(function(data){
|
||||
$(this).css('background-image', null)
|
||||
.toggleClass('success_icon')
|
||||
.toggleClass('failure_icon');
|
||||
}, $(this)));
|
||||
e.preventDefault();
|
||||
});
|
||||
});
|
||||
<%= File.open(File.expand_path('../../../../../public/javascripts/refinerycms-blog.js', __FILE__), 'r').read %>
|
||||
</script>
|
||||
<% end %>
|
|
@ -17,6 +17,7 @@ Gem::Specification.new do |s|
|
|||
s.homepage = %q{http://refinerycms.com}
|
||||
s.authors = %w(Resolve\\ Digital Neoteric\\ Design)
|
||||
s.require_paths = %w(lib)
|
||||
s.add_dependency('refinerycms', '~> 0.9.7.12')
|
||||
|
||||
s.files = %w(
|
||||
#{files.join("\n ")}
|
||||
|
|
|
@ -2,7 +2,7 @@ module Refinery
|
|||
module Blog
|
||||
class << self
|
||||
def version
|
||||
%q{0.9.8.dev1}
|
||||
%q{0.9.8.dev2}
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -0,0 +1,40 @@
|
|||
$(document).ready(function(){
|
||||
$('div#actions.multilist > ul:not(.search_list) li a[href$=' + window.location.pathname + ']')
|
||||
.parent().addClass('selected');
|
||||
|
||||
$('div#actions.multilist > ul:not(.search_list) li > a').each(function(i,a){
|
||||
if ($(this).data('dialog-title') == null) {
|
||||
$(this).bind('click', function(){
|
||||
$(this).css('background-image', "url('/images/refinery/icons/ajax-loader.gif') !important");
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$('ul.collapsible_menu').each(function(i, ul) {
|
||||
(first_li = $(this).children('li:first')).after(div=$("<div></div>"));
|
||||
if (($(this).children('li.selected')).length == 0) {
|
||||
div.hide();
|
||||
}
|
||||
$(this).children('li:not(:first)').appendTo(div);
|
||||
|
||||
first_li.find('> a').click(function(e){
|
||||
$(this).parent().next('div').animate({
|
||||
opacity: 'toggle'
|
||||
, height: 'toggle'
|
||||
}, 250, $.proxy(function(){
|
||||
$(this).css('background-image', null);
|
||||
}, $(this))
|
||||
);
|
||||
e.preventDefault();
|
||||
});
|
||||
});
|
||||
|
||||
$('.success_icon, .failure_icon').bind('click', function(e) {
|
||||
$.get($(this).attr('href'), $.proxy(function(data){
|
||||
$(this).css('background-image', null)
|
||||
.toggleClass('success_icon')
|
||||
.toggleClass('failure_icon');
|
||||
}, $(this)));
|
||||
e.preventDefault();
|
||||
});
|
||||
});
|
|
@ -0,0 +1,33 @@
|
|||
.comments_icon {
|
||||
background-image: url('/images/refinery/icons/comments.png');
|
||||
}
|
||||
.comment_icon {
|
||||
background-image: url('/images/refinery/icons/comment.png');
|
||||
}
|
||||
.comment_cross_icon {
|
||||
background-image: url('/images/refinery/icons/comment_cross.png');
|
||||
}
|
||||
.comment_tick_icon {
|
||||
background-image: url('/images/refinery/icons/comment_tick.png');
|
||||
}
|
||||
.folder_icon {
|
||||
background-image: url('/images/refinery/icons/folder.png');
|
||||
}
|
||||
.folder_add_icon {
|
||||
background-image: url('/images/refinery/icons/folder_add.png');
|
||||
}
|
||||
.folder_edit_icon {
|
||||
background-image: url('/images/refinery/icons/folder_edit.png');
|
||||
}
|
||||
.settings_icon {
|
||||
background-image: url('/images/refinery/icons/cog.png');
|
||||
}
|
||||
.page_icon {
|
||||
background-image: url('/images/refinery/icons/page.png');
|
||||
}
|
||||
.page_copy_icon {
|
||||
background-image: url('/images/refinery/icons/page_copy.png');
|
||||
}
|
||||
.page_add_icon {
|
||||
background-image: url('/images/refinery/icons/page_add.png');
|
||||
}
|
|
@ -1,13 +1,14 @@
|
|||
Gem::Specification.new do |s|
|
||||
s.name = %q{refinerycms-blog}
|
||||
s.version = %q{0.9.8.dev1}
|
||||
s.version = %q{0.9.8.dev2}
|
||||
s.description = %q{A really straightforward open source Ruby on Rails blog engine designed for integration with RefineryCMS.}
|
||||
s.date = %q{2010-08-09}
|
||||
s.date = %q{2010-08-18}
|
||||
s.summary = %q{Ruby on Rails blogging engine for RefineryCMS.}
|
||||
s.email = %q{info@refinerycms.com}
|
||||
s.homepage = %q{http://refinerycms.com}
|
||||
s.authors = %w(Resolve\ Digital Neoteric\ Design)
|
||||
s.require_paths = %w(lib)
|
||||
s.add_dependency('refinerycms', '~> 0.9.7.12')
|
||||
|
||||
s.files = %w(
|
||||
app
|
||||
|
@ -38,6 +39,8 @@ Gem::Specification.new do |s|
|
|||
app/views/admin/blog/posts/edit.html.erb
|
||||
app/views/admin/blog/posts/index.html.erb
|
||||
app/views/admin/blog/posts/new.html.erb
|
||||
app/views/admin/blog/settings
|
||||
app/views/admin/blog/settings/notification_recipients.html.erb
|
||||
app/views/blog_posts
|
||||
app/views/blog_posts/index.html.erb
|
||||
app/views/blog_posts/show.html.erb
|
||||
|
@ -56,9 +59,26 @@ Gem::Specification.new do |s|
|
|||
lib
|
||||
lib/gemspec.rb
|
||||
lib/refinerycms-blog.rb
|
||||
public
|
||||
public/images
|
||||
public/images/refinerycms-blog
|
||||
public/images/refinerycms-blog/icons
|
||||
public/javascripts
|
||||
public/javascripts/refinerycms-blog.js
|
||||
public/stylesheets
|
||||
public/stylesheets/refinerycms-blog.css
|
||||
rails
|
||||
rails/init.rb
|
||||
readme.md
|
||||
spec
|
||||
spec/factories
|
||||
spec/factories/blog_categories.rb
|
||||
spec/factories/blog_comments.rb
|
||||
spec/factories/blog_posts.rb
|
||||
spec/models
|
||||
spec/models/blog_categories_spec.rb
|
||||
spec/models/blog_comments_spec.rb
|
||||
spec/models/blog_posts_spec.rb
|
||||
)
|
||||
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue