istart-rails 0.0.1

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/.gitignore ADDED
@@ -0,0 +1,4 @@
1
+ *.gem
2
+ .bundle
3
+ Gemfile.lock
4
+ pkg/*
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source "http://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in istart-rails.gemspec
4
+ gemspec
data/License.txt ADDED
@@ -0,0 +1,22 @@
1
+ (The MIT License)
2
+
3
+ Copyright (c) 2011 Sébastien Grosjean
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
20
+ CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21
+ TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22
+ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,31 @@
1
+ # istart-rails
2
+
3
+ iStart-Rails is a set of common helpers to improve your app and speed up it's development
4
+
5
+ ## Helpers
6
+
7
+ * Disable submit input after form submission
8
+ * Open external links in new window (links must have the class name `external`)
9
+ * Consider element with `data-link-url` as links (also support opening in new window with the class name `external`)
10
+ * Init [Chosen](http://harvesthq.github.com/chosen/) if in use
11
+
12
+ ## Requirements
13
+
14
+ jquery-rails
15
+ rails >= 3.1 (with Asset Pipeline)
16
+
17
+ ## Install
18
+
19
+ Add this to your application `Gemfile`
20
+
21
+ gem 'istart-rails'
22
+
23
+ Within `app/assets/javascripts/application.js` add the following
24
+
25
+ //= require jquery
26
+ ...
27
+ //= require istart
28
+
29
+ ## License
30
+
31
+ MIT License. Copyright 2011 Sébastien Grosjean, sponsored by [BookingSync, Vacation Rental's Booking Calendar Software](http://www.bookingsync.com)
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
@@ -0,0 +1,20 @@
1
+ jQuery ->
2
+ # Disable submit input after form submission
3
+ $(document).on "submit", 'form', (event) ->
4
+ $('input[type=submit]', @).attr('disabled', 'disabled')
5
+
6
+ # External links
7
+ $(document).on "click", 'a.external', (event) ->
8
+ event.preventDefault()
9
+ window.open(@href)
10
+
11
+ # Block as links
12
+ $(document).on "click", '*[data-link-url]', (event) ->
13
+ url = $(@).data('link-url')
14
+ if $(@).hasClass('external')
15
+ window.open(url)
16
+ else
17
+ window.location = url
18
+
19
+ # Chosen: http://harvesthq.github.com/chosen/
20
+ $(".chzn-select").chosen()
@@ -0,0 +1,24 @@
1
+ # -*- encoding: utf-8 -*-
2
+ $:.push File.expand_path("../lib", __FILE__)
3
+ require "istart/rails/version"
4
+
5
+ Gem::Specification.new do |s|
6
+ s.name = "istart-rails"
7
+ s.version = Istart::Rails::VERSION
8
+ s.authors = ["Sébastien Grosjean"]
9
+ s.email = ["public@zencocoon.com"]
10
+ s.homepage = ""
11
+ s.summary = %q{Assets helpers to speed up new app development}
12
+ s.description = %q{iStart-Rails is a set of common helpers to improve your app and speed up it's development}
13
+
14
+ s.rubyforge_project = "istart-rails"
15
+
16
+ s.files = `git ls-files`.split("\n")
17
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
18
+ s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
19
+ s.require_paths = ["lib"]
20
+
21
+ # specify any dependencies here; for example:
22
+ # s.add_development_dependency "rspec"
23
+ s.add_runtime_dependency "jquery-rails"
24
+ end
@@ -0,0 +1,6 @@
1
+ module Istart
2
+ module Rails
3
+ class Engine < ::Rails::Engine
4
+ end
5
+ end
6
+ end
@@ -0,0 +1,5 @@
1
+ module Istart
2
+ module Rails
3
+ VERSION = "0.0.1"
4
+ end
5
+ end
@@ -0,0 +1,6 @@
1
+ module Istart
2
+ module Rails
3
+ require "istart/rails/engine"
4
+ require "istart/rails/version"
5
+ end
6
+ end
@@ -0,0 +1 @@
1
+ require 'istart/rails'
metadata ADDED
@@ -0,0 +1,69 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: istart-rails
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Sébastien Grosjean
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2012-02-25 00:00:00.000000000Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: jquery-rails
16
+ requirement: &70222543396000 !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
21
+ version: '0'
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: *70222543396000
25
+ description: iStart-Rails is a set of common helpers to improve your app and speed
26
+ up it's development
27
+ email:
28
+ - public@zencocoon.com
29
+ executables: []
30
+ extensions: []
31
+ extra_rdoc_files: []
32
+ files:
33
+ - .gitignore
34
+ - Gemfile
35
+ - License.txt
36
+ - README.md
37
+ - Rakefile
38
+ - app/assets/javascripts/istart.js.coffee
39
+ - istart-rails.gemspec
40
+ - lib/istart-rails.rb
41
+ - lib/istart/rails.rb
42
+ - lib/istart/rails/engine.rb
43
+ - lib/istart/rails/version.rb
44
+ homepage: ''
45
+ licenses: []
46
+ post_install_message:
47
+ rdoc_options: []
48
+ require_paths:
49
+ - lib
50
+ required_ruby_version: !ruby/object:Gem::Requirement
51
+ none: false
52
+ requirements:
53
+ - - ! '>='
54
+ - !ruby/object:Gem::Version
55
+ version: '0'
56
+ required_rubygems_version: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ requirements: []
63
+ rubyforge_project: istart-rails
64
+ rubygems_version: 1.8.17
65
+ signing_key:
66
+ specification_version: 3
67
+ summary: Assets helpers to speed up new app development
68
+ test_files: []
69
+ has_rdoc: