starburstgem / starburst

In-app announcements to users in your Rails app
MIT License
257 stars 29 forks source link

Add partial with bootstrap panel markup #11

Open jscharf opened 8 years ago

jscharf commented 8 years ago

This change builds on the existing partial that using Bootstrap compatible markup, only using a panel instead of an alert. A panel would be useful for anyone who may want to insert the announcement somewhere in the UI with a little more screen real estate.

I think the panel heading provides a good spot for an icon, a title, and the close button that dismisses the announcement. I could later modify this to include the title of the announcement as the title of the panel as well, but thought just simply Announcement would be good for the panel title for now.

csm123 commented 8 years ago

Thanks for this! I gave it a test and the X is rendering a bit below the title bar on the latest Bootstrap.

screen shot 2015-09-13 at 9 07 48 am

Feel free to take a look by grabbing https://github.com/csm123/starburst-bootstrap-example, running bundle install and rake db:migrate on it, and adding an announcement through Rails console. Then head to /pages/home to see it.

jscharf commented 8 years ago

No problem! I thought a panel might be a nice alternative for anyone who might want to display more information.

I followed the steps to get the starburst-bootstrap-example project running, but I am unable to see the announcement that I created in the Rails console. I'll try to figure out what's going on there.

csm123 commented 8 years ago

Thanks! Make sure you go to /pages/home and create an account and login, since announcements are shown only to logged in users On Sun, Sep 20, 2015 at 7:47 PM Josh Scharf notifications@github.com wrote:

No problem! I thought a panel might be a nice alternative for anyone who might want to display more information.

I followed the steps to get the starburst-bootstrap-example project running, but I am unable to see the announcement that I created in the Rails console. I'll try to figure out what's going on there.

— Reply to this email directly or view it on GitHub https://github.com/csm123/starburst/pull/11#issuecomment-141826953.

jscharf commented 8 years ago

Oh ok yeah that's why I couldn't see it - I wasn't logged in. When I went to the /pages/home route in the browser, I just saw the <p>This is the homepage</p> markup and no link to log in. I see from the schema file that there is a users table though, so I'll see if I can authenticate in order to see the announcement.

jscharf commented 8 years ago

Ok so I did some reading about Devise and I was able to log in and see the misaligned close button. I moved the close button markup above the header markup and added a pull-right class and now it appears to be lined up better.

jscharf commented 7 years ago

@csm123 I looked at the build details from Travis CI, and it looks like some of the build jobs failed and some of them succeeded. I checked the logs for the jobs that failed, and each time the error was

NoMethodError: undefined method `spec' for nil:NilClass
An error occurred while installing
starburst (1.0.3), and Bundler cannot
continue.
Make sure that `gem install starburst -v
'1.0.3'` succeeds before bundling.
The command "bundle install" failed and exited with 5 during .
Your build has been stopped.

It looks like the build jobs failed when using Ruby 1.9.3 and 2.1.3, but succeeded when using Ruby 2.0.0. Do you know why this might happen for some of the jobs but not all of them?