happydatepicker 0.0.10 → 0.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README.md CHANGED
@@ -18,6 +18,14 @@ Or install it yourself as:
18
18
 
19
19
  ## Usage
20
20
 
21
+ in application.js you need to require:
22
+
23
+ //=require datepicker
24
+ //=require happydatepicker
25
+
26
+ in application.css you need to include
27
+ *=require datepicker.css
28
+
21
29
  From within your coffeescript file just do as follows:
22
30
 
23
31
  new HappyDatePicker($("#your_element"))
@@ -1,5 +1,5 @@
1
1
  module Happydatepicker
2
2
  module Rails
3
- VERSION = "0.0.10"
3
+ VERSION = "0.0.11"
4
4
  end
5
5
  end
@@ -0,0 +1,12 @@
1
+ class @HappyDatePicker
2
+
3
+ constructor: (element) ->
4
+ $(element).DatePicker
5
+ flat: false
6
+ date: new Date()
7
+ current: new Date()
8
+ calendars: 1
9
+ starts: 1
10
+ onChange: (formated, dates) ->
11
+ $(element).val formated
12
+ $(element).DatePickerHide()
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: happydatepicker
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.10
4
+ version: 0.0.11
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -37,7 +37,7 @@ files:
37
37
  - vendor/assets/images/datepicker_tl.png
38
38
  - vendor/assets/images/datepicker_tr.png
39
39
  - vendor/assets/javascripts/datepicker.js
40
- - vendor/assets/javascripts/happydatepicker.js
40
+ - vendor/assets/javascripts/happydatepicker.js.coffee
41
41
  - vendor/assets/stylesheets/datepicker.css
42
42
  homepage: http://objectivesheep.com
43
43
  licenses: []
@@ -1,20 +0,0 @@
1
-
2
- this.HappyDatePicker = (function() {
3
-
4
- function HappyDatePicker(element) {
5
- $(element).DatePicker({
6
- flat: false,
7
- date: new Date(),
8
- current: new Date(),
9
- calendars: 1,
10
- starts: 1,
11
- onChange: function(formated, dates) {
12
- $(element).val(formated);
13
- return $(element).DatePickerHide();
14
- }
15
- });
16
- }
17
-
18
- return HappyDatePicker;
19
-
20
- })();