maxchars 0.0.4 → 0.0.5

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.
@@ -1,3 +1,3 @@
1
1
  module Maxchars
2
- VERSION = "0.0.4"
2
+ VERSION = "0.0.5"
3
3
  end
metadata CHANGED
@@ -1,65 +1,87 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: maxchars
3
- version: !ruby/object:Gem::Version
4
- version: 0.0.4
3
+ version: !ruby/object:Gem::Version
4
+ hash: 21
5
5
  prerelease:
6
+ segments:
7
+ - 0
8
+ - 0
9
+ - 5
10
+ version: 0.0.5
6
11
  platform: ruby
7
- authors:
12
+ authors:
8
13
  - Alexander Presber
9
14
  autorequire:
10
15
  bindir: bin
11
16
  cert_chain: []
12
- date: 2012-07-04 00:00:00.000000000Z
13
- dependencies:
14
- - !ruby/object:Gem::Dependency
17
+
18
+ date: 2012-07-04 00:00:00 Z
19
+ dependencies:
20
+ - !ruby/object:Gem::Dependency
15
21
  name: jquery-rails
16
- requirement: &70240659838860 !ruby/object:Gem::Requirement
22
+ prerelease: false
23
+ requirement: &id001 !ruby/object:Gem::Requirement
17
24
  none: false
18
- requirements:
19
- - - ! '>='
20
- - !ruby/object:Gem::Version
21
- version: '1.0'
25
+ requirements:
26
+ - - ">="
27
+ - !ruby/object:Gem::Version
28
+ hash: 15
29
+ segments:
30
+ - 1
31
+ - 0
32
+ version: "1.0"
22
33
  type: :runtime
23
- prerelease: false
24
- version_requirements: *70240659838860
25
- description: jquery plugin to restrict characters that can be put into an input field
26
- or text area. Displays remaining characters in a tipsy tooltip.
27
- email:
34
+ version_requirements: *id001
35
+ description: jquery plugin to restrict characters that can be put into an input field or text area. Displays remaining characters in a tipsy tooltip.
36
+ email:
28
37
  - post@momolog.info
29
38
  executables: []
39
+
30
40
  extensions: []
41
+
31
42
  extra_rdoc_files: []
32
- files:
43
+
44
+ files:
33
45
  - .gitignore
34
46
  - Gemfile
35
47
  - Rakefile
36
- - lib/assets/javascripts/maxChars.js
37
48
  - lib/assets/javascripts/maxChars.js.coffee
38
49
  - lib/maxchars.rb
39
50
  - lib/maxchars/version.rb
40
51
  - maxchars.gemspec
41
- homepage: ''
52
+ homepage: ""
42
53
  licenses: []
54
+
43
55
  post_install_message:
44
56
  rdoc_options: []
45
- require_paths:
57
+
58
+ require_paths:
46
59
  - lib
47
- required_ruby_version: !ruby/object:Gem::Requirement
60
+ required_ruby_version: !ruby/object:Gem::Requirement
48
61
  none: false
49
- requirements:
50
- - - ! '>='
51
- - !ruby/object:Gem::Version
52
- version: '0'
53
- required_rubygems_version: !ruby/object:Gem::Requirement
62
+ requirements:
63
+ - - ">="
64
+ - !ruby/object:Gem::Version
65
+ hash: 3
66
+ segments:
67
+ - 0
68
+ version: "0"
69
+ required_rubygems_version: !ruby/object:Gem::Requirement
54
70
  none: false
55
- requirements:
56
- - - ! '>='
57
- - !ruby/object:Gem::Version
58
- version: '0'
71
+ requirements:
72
+ - - ">="
73
+ - !ruby/object:Gem::Version
74
+ hash: 3
75
+ segments:
76
+ - 0
77
+ version: "0"
59
78
  requirements: []
79
+
60
80
  rubyforge_project: maxchars
61
81
  rubygems_version: 1.8.15
62
82
  signing_key:
63
83
  specification_version: 3
64
84
  summary: input field character restriction
65
85
  test_files: []
86
+
87
+ has_rdoc:
@@ -1,35 +0,0 @@
1
- (function() {
2
-
3
- $.fn.extend({
4
- maxChars: function(setMaxLen) {
5
- return this.each(function() {
6
- return $(this).tipsy({
7
- gravity: 'w',
8
- trigger: 'focus',
9
- html: true
10
- }).each(function() {
11
- var el, hardLimit, maxLen, template;
12
- el = $(this);
13
- maxLen = setMaxLen != null ? setMaxLen : el.data('maxlen');
14
- template = el.data('maxlen-text') || 'remaining chars: %x';
15
- hardLimit = !el.data('maxlen-soft');
16
- return el.data('doUpdateTitle', function() {
17
- var len, remaining, remainingText;
18
- len = el.val().length;
19
- if (hardLimit && (len > maxLen)) {
20
- el.val(el.val().substr(0, maxLen));
21
- len = maxLen;
22
- }
23
- remaining = maxLen - len;
24
- remainingText = template.replace(/%x/, remaining);
25
- el.attr('title', remainingText).tipsy('hide').tipsy('show');
26
- return len;
27
- });
28
- }).live('keyup', function() {
29
- return $(this).data('doUpdateTitle')();
30
- });
31
- });
32
- }
33
- });
34
-
35
- }).call(this);