compass-jquery-plugin 0.2.4.99 → 0.2.4.100

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION.yml CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
- :commit: 99
2
+ :commit: 100
3
3
  :patch: 4
4
4
  :minor: 2
5
5
  :major: 0
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{compass-jquery-plugin}
8
- s.version = "0.2.4.99"
8
+ s.version = "0.2.4.100"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Kosmas Schuetz"]
@@ -368,6 +368,8 @@ Gem::Specification.new do |s|
368
368
  "templates/jrails/i18n/jquery.ui/datepicker-zh-TW.min.js",
369
369
  "templates/jrails/jquery-ui.js",
370
370
  "templates/jrails/jquery-ui.min.js",
371
+ "templates/jrails/jquery.1.3.2.js",
372
+ "templates/jrails/jquery.1.3.2.min.js",
371
373
  "templates/jrails/jquery.compat-1.3.js",
372
374
  "templates/jrails/jquery.compat-1.3.min.js",
373
375
  "templates/jrails/jquery.js",
@@ -5,8 +5,10 @@ require 'lib/handle_js_files'
5
5
  JRAILS_SRC = File.join(GEM_ROOT, 'src', 'jrails')
6
6
  JRAILS_SRC_SCRIPTS = JRAILS_SRC + "/*.js"
7
7
 
8
- JQUERY_SRC = File.join(GEM_ROOT, 'src', 'jquery-1.4')
9
- JQUERY_SRC_SCRIPTS = JQUERY_SRC + "/*.js"
8
+ JQUERY_13_SRC = File.join(GEM_ROOT, 'src', 'jquery-1.3.2')
9
+ JQUERY_13_SRC_SCRIPTS = JQUERY_13_SRC + "/*.js"
10
+ JQUERY_14_SRC = File.join(GEM_ROOT, 'src', 'jquery-1.4')
11
+ JQUERY_14_SRC_SCRIPTS = JQUERY_14_SRC + "/*.js"
10
12
 
11
13
  JQUERY_UI_SRC = File.join(GEM_ROOT, 'src', 'jquery.ui-1.7.2')
12
14
  JQUERY_UI_SRC_SCRIPTS = File.join(JQUERY_UI_SRC, 'js') + "/*.js"
@@ -49,38 +51,67 @@ namespace :build do
49
51
  end
50
52
  manifest.print "javascript 'jrails.min.js'\n"
51
53
 
52
- # jQuery
54
+ # jQuery 1.4
53
55
 
54
56
  open File.join(JRAILS_DEST_TEMPLATES, 'jquery.js'), 'w' do |f|
55
- f.print concat_files(all_files(JQUERY_SRC_SCRIPTS))
57
+ f.print concat_files(all_files(JQUERY_14_SRC_SCRIPTS))
56
58
  end
57
59
  manifest.print "javascript 'jquery.js'\n"
58
60
 
59
61
  open File.join(JRAILS_DEST_TEMPLATES, 'jquery.min.js'), 'w' do |f|
60
- f.print compress_js(all_files(JQUERY_SRC_SCRIPTS))
62
+ f.print compress_js(all_files(JQUERY_14_SRC_SCRIPTS))
61
63
  end
62
64
  manifest.print "javascript 'jquery.min.js'\n"
63
65
 
64
66
  # jQuery 1.3 compatibility
65
67
 
66
68
  open File.join(JRAILS_DEST_TEMPLATES, 'jquery.compat-1.3.js'), 'w' do |f|
67
- f.print concat_files(all_files(JQUERY_SRC + "/jquery.compat-1.3.js"))
69
+ f.print concat_files(all_files(JQUERY_14_SRC + "/jquery.compat-1.3.js"))
68
70
  end
69
71
  manifest.print "javascript 'jquery.compat-1.3.js'\n"
70
72
 
71
73
  open File.join(JRAILS_DEST_TEMPLATES, 'jquery.compat-1.3.min.js'), 'w' do |f|
72
- f.print compress_js(all_files(JQUERY_SRC + "/jquery.compat-1.3.js"))
74
+ f.print compress_js(all_files(JQUERY_14_SRC + "/jquery.compat-1.3.js"))
73
75
  end
74
76
  manifest.print "javascript 'jquery.compat-1.3.min.js'\n"
77
+
75
78
 
79
+ # jQuery 1.4 Plugins
76
80
 
81
+ ['plugins'].each do |path|
82
+ Dir.foreach File.join(JQUERY_14_SRC, path) do |file|
83
+ next unless /\.js$/ =~ file
84
+ js = File.read File.join(JQUERY_14_SRC, path, file)
85
+ manifest.print "javascript '#{file}'\n"
86
+ open File.join(JRAILS_DEST_TEMPLATES, file), 'w' do |f|
87
+ f.write js
88
+ end
89
+ file.gsub!(/\.js$/, '.min.js')
90
+ manifest.print "javascript '#{file}'\n"
91
+ open File.join(JRAILS_DEST_TEMPLATES, file), 'w' do |f|
92
+ f.write compress_js(js)
93
+ end
94
+ end
95
+ end
77
96
 
78
- # jQuery Plugins
97
+ # jQuery 1.3
98
+
99
+ open File.join(JRAILS_DEST_TEMPLATES, 'jquery.1.3.2.js'), 'w' do |f|
100
+ f.print concat_files(all_files(JQUERY_13_SRC_SCRIPTS))
101
+ end
102
+ manifest.print "javascript 'jquery.1.3.2.js'\n"
103
+
104
+ open File.join(JRAILS_DEST_TEMPLATES, 'jquery.1.3.2.min.js'), 'w' do |f|
105
+ f.print compress_js(all_files(JQUERY_13_SRC_SCRIPTS))
106
+ end
107
+ manifest.print "javascript 'jquery.1.3.2.min.js'\n"
108
+
109
+ # jQuery 1.3 Plugins
79
110
 
80
111
  ['plugins'].each do |path|
81
- Dir.foreach File.join(JQUERY_SRC, path) do |file|
112
+ Dir.foreach File.join(JQUERY_13_SRC, path) do |file|
82
113
  next unless /\.js$/ =~ file
83
- js = File.read File.join(JQUERY_SRC, path, file)
114
+ js = File.read File.join(JQUERY_13_SRC, path, file)
84
115
  manifest.print "javascript '#{file}'\n"
85
116
  open File.join(JRAILS_DEST_TEMPLATES, file), 'w' do |f|
86
117
  f.write js
@@ -91,7 +122,7 @@ namespace :build do
91
122
  f.write compress_js(js)
92
123
  end
93
124
  end
94
- end
125
+ end
95
126
 
96
127
  # jQuery.UI
97
128
 
@@ -21,6 +21,9 @@ ActionView::Helpers::AssetTagHelper.register_javascript_expansion :jquery => ['j
21
21
  ActionView::Helpers::AssetTagHelper.register_javascript_expansion :jquery_compat => ['jquery.min', 'jquery.compat-1.3.min', 'jquery-ui.min']
22
22
  ActionView::Helpers::AssetTagHelper.register_javascript_expansion :defaults_compat => ['jquery.min', 'jquery.compat-1.3.min', 'jquery-ui.min', 'jrails.min']
23
23
 
24
+ ActionView::Helpers::AssetTagHelper.register_javascript_expansion :jquery_13 => ['jquery.1.3.2.min', 'jquery-ui.min']
25
+ ActionView::Helpers::AssetTagHelper.register_javascript_expansion :defaults_13 => ['jquery.1.3.2.min', 'jquery-ui.min', 'jrails.min']
26
+
24
27
  #ActionView::Helpers::AssetTagHelper.register_stylesheet_expansion :jrails => ['compiled/jquery.ui/ui.theme.css']
25
28
  #ActionView::Helpers::AssetTagHelper.register_stylesheet_expansion :jquery => ['compiled/jquery.ui/ui.theme.css']
26
29