Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#580 stylesheet registration #723

Closed

Conversation

macfanatic
Copy link
Contributor

Added ActiveAdmin::Stylesheet class that allows user to register a stylesheet with ActiveAdmin while providing an options hash as one would normally use in layouts.

Example:

register_stylesheet "main.css"
register_stylesheet "print.css", :media => :print

Matthew Brewer added 2 commits November 4, 2011 17:16
…ylesheet with ActiveAdmin while providing an options hash as one would normally use in layouts.
…y available options hash for CSS registration
@macfanatic macfanatic mentioned this pull request Nov 4, 2011
ActiveAdmin.register Post
"""
When I am on the index page for posts
Then I should see the css file "some-random-css.css"
Then I should see the css file "some-random-css.css" of media :print
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you wrap the media parameter between double quotes? It's a convention that we'd like to see in ActiveAdmin. So the step would be:

Then I should see the css file "some-random-css.css" of media "print"

@macfanatic
Copy link
Contributor Author

No problem, I can make those changes and update the branch sometime this week and let you know once those are in place.

@pcreux
Copy link
Contributor

pcreux commented Nov 21, 2011

@macfanatic This is a great contribution, thank you very much for this!

@macfanatic
Copy link
Contributor Author

Believe this latest commit includes all requested tweaks.

@gregbell
Copy link
Contributor

Awesome. I'll get it merged in

@gregbell
Copy link
Contributor

gregbell commented Dec 1, 2011

Merged in to master! Thanks for the great commits @macfanatic!

@gregbell gregbell closed this Dec 1, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants