README.md in dynaspan-0.0.5 vs README.md in dynaspan-0.0.6
- old
+ new
@@ -1,14 +1,16 @@
##Dynaspan
+[![Gem Version](https://badge.fury.io/rb/dynaspan.svg)](http://badge.fury.io/rb/dynaspan)
+#####[JSFiddle Demo](http://jsfiddle.net/680v09y8/)
Dynaspan is an AJAX tool for Rails to update one field of any object without interfering with your website experience. The user will see the web page as normal text. Where ever you've placed a Dynaspan field people can click on the text and it transforms into text entry. As soon as the person moves away from that entry it sends the update to the server.
Dynaspan also accepts updating an attribute for a nested object, but only 1 level deep.
###Installation
- - [ ] Add `gem 'dynaspan', '~> 0.0.4'` to your Gemfile.
+ - [ ] Add `gem 'dynaspan'` to your Gemfile.
- [ ] Run `bundle`.
- [ ] Next add `include Dynaspan::ApplicationHelper` inside your **ApplicationHelper** module.
- [ ] Add `//= require dynaspan/dynaspan` to your **application.js** file.
- [ ] And it's installed!
@@ -38,9 +40,19 @@
###It's too easy!
**You're welcome!**
-- Daniel P. Clark
+
+###Styles
+
+As of version 0.0.6 a class will be dynamically added/removed to a div tag containing the class "dyna-span".
+That class is "ds-content-present". The purpose of this class is to allow CSS content styles depending on
+whether your text exists or not. The '[edit]' text you can use as a parameter normally drops below the input
+box. If you don't want it to drop you can style it with the proper CSS selector for content present. E.G.
+`.ds-content-present > dyna-span-edit-text { margin-top:-18px; }` You can set the height to whatever your input
+field height is to maintain the position of the edit text. With jQuery you can also set style for
+hidden and visible changes.
###License
The MIT License (MIT)