zebra-datepicker-i18n 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE +23 -0
- data/Rakefile +1 -0
- data/app/assets/javascripts/zebra-datepicker-i18n.js.erb +30 -0
- data/config/locales/en.yml +3 -0
- data/config/locales/fr.yml +3 -0
- data/config/locales/nl.yml +3 -0
- data/lib/zebra-datepicker-i18n.rb +7 -0
- data/lib/zebra-datepicker-i18n/engine.rb +11 -0
- metadata +108 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 31ecbca813f0bf7abce756f6cdfca7f60471391f
|
4
|
+
data.tar.gz: 9348f18a2f9cb650de3e7ce05c3c1df15635044d
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: a9eacde20992ac5831464bf5c3cbba6df2ea81a2407c87e475d4a6281e9cf76c715274dab7df18b75553bdc254e95bab6067a74b22b89547bf454d11e62e9085
|
7
|
+
data.tar.gz: 064bd9be7743de3eb502b29b03f002cb90024db41f09c11bbb85f787d5eddca357532aa93a3c21ac9e1b874838c94c51a97ea33717f79902cb29ee7a195e5eb7
|
data/LICENSE
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
Copyright (c) 2016, Ivaldi
|
2
|
+
All rights reserved.
|
3
|
+
|
4
|
+
Redistribution and use in source and binary forms, with or without
|
5
|
+
modification, are permitted provided that the following conditions are met:
|
6
|
+
|
7
|
+
* Redistributions of source code must retain the above copyright notice, this
|
8
|
+
list of conditions and the following disclaimer.
|
9
|
+
|
10
|
+
* Redistributions in binary form must reproduce the above copyright notice,
|
11
|
+
this list of conditions and the following disclaimer in the documentation
|
12
|
+
and/or other materials provided with the distribution.
|
13
|
+
|
14
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
15
|
+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
16
|
+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
17
|
+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
18
|
+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
19
|
+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
20
|
+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
21
|
+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
22
|
+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
23
|
+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
data/Rakefile
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
require 'bundler/gem_tasks'
|
@@ -0,0 +1,30 @@
|
|
1
|
+
$.fn.Zebra_DatePicker_I18n = function(options) {
|
2
|
+
locales = {};
|
3
|
+
<% I18n.available_locales.map(&:to_sym).each do |locale| %>
|
4
|
+
locales['<%= locale %>'] = {
|
5
|
+
days: [
|
6
|
+
'<%= raw I18n.t('date.day_names', locale: locale).join('\',\'') %>'
|
7
|
+
],
|
8
|
+
days_abbr: [
|
9
|
+
'<%= raw I18n.t('date.abbr_day_names', locale: locale)
|
10
|
+
.join('\',\'') %>'
|
11
|
+
],
|
12
|
+
format: '<%= I18n.t('date.formats.default').gsub '%', '' %>',
|
13
|
+
months: [
|
14
|
+
'<%= raw I18n.t('date.month_names', locale: locale)[1..12]
|
15
|
+
.join('\',\'') %>'
|
16
|
+
],
|
17
|
+
months_abbr: [
|
18
|
+
'<%= raw I18n.t('date.abbr_month_names', locale: locale)[1..12]
|
19
|
+
.join('\',\'') %>'
|
20
|
+
],
|
21
|
+
show_select_today: '<%= I18n.t :today, locale: locale %>',
|
22
|
+
lang_clear_date: '<%= I18n.t :clear, locale: locale %>'
|
23
|
+
};
|
24
|
+
<% end %>
|
25
|
+
|
26
|
+
options = $.extend({}, options, locales[options['locale']]);
|
27
|
+
delete options['locale']
|
28
|
+
|
29
|
+
this.Zebra_DatePicker(options);
|
30
|
+
};
|
metadata
ADDED
@@ -0,0 +1,108 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: zebra-datepicker-i18n
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Frank Groeneveld
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-07-14 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rails
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '4'
|
20
|
+
- - "<"
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: '6'
|
23
|
+
type: :runtime
|
24
|
+
prerelease: false
|
25
|
+
version_requirements: !ruby/object:Gem::Requirement
|
26
|
+
requirements:
|
27
|
+
- - ">="
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '4'
|
30
|
+
- - "<"
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '6'
|
33
|
+
- !ruby/object:Gem::Dependency
|
34
|
+
name: zebra-datepicker-rails
|
35
|
+
requirement: !ruby/object:Gem::Requirement
|
36
|
+
requirements:
|
37
|
+
- - '='
|
38
|
+
- !ruby/object:Gem::Version
|
39
|
+
version: 1.9.2
|
40
|
+
type: :runtime
|
41
|
+
prerelease: false
|
42
|
+
version_requirements: !ruby/object:Gem::Requirement
|
43
|
+
requirements:
|
44
|
+
- - '='
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: 1.9.2
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: rails-i18n
|
49
|
+
requirement: !ruby/object:Gem::Requirement
|
50
|
+
requirements:
|
51
|
+
- - ">="
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '4'
|
54
|
+
- - "<"
|
55
|
+
- !ruby/object:Gem::Version
|
56
|
+
version: '6'
|
57
|
+
type: :runtime
|
58
|
+
prerelease: false
|
59
|
+
version_requirements: !ruby/object:Gem::Requirement
|
60
|
+
requirements:
|
61
|
+
- - ">="
|
62
|
+
- !ruby/object:Gem::Version
|
63
|
+
version: '4'
|
64
|
+
- - "<"
|
65
|
+
- !ruby/object:Gem::Version
|
66
|
+
version: '6'
|
67
|
+
description: |-
|
68
|
+
Extend Zebra Datepicker with translations and localisation
|
69
|
+
based on the excellent rails-i18n and zebra-datepicker-rails gems
|
70
|
+
email:
|
71
|
+
- frank@ivaldi.nl
|
72
|
+
executables: []
|
73
|
+
extensions: []
|
74
|
+
extra_rdoc_files: []
|
75
|
+
files:
|
76
|
+
- LICENSE
|
77
|
+
- Rakefile
|
78
|
+
- app/assets/javascripts/zebra-datepicker-i18n.js.erb
|
79
|
+
- config/locales/en.yml
|
80
|
+
- config/locales/fr.yml
|
81
|
+
- config/locales/nl.yml
|
82
|
+
- lib/zebra-datepicker-i18n.rb
|
83
|
+
- lib/zebra-datepicker-i18n/engine.rb
|
84
|
+
homepage: https://github.com/ivaldi/zebra-datepicker-i18n
|
85
|
+
licenses:
|
86
|
+
- BSD-2-Clause
|
87
|
+
metadata: {}
|
88
|
+
post_install_message:
|
89
|
+
rdoc_options: []
|
90
|
+
require_paths:
|
91
|
+
- lib
|
92
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
98
|
+
requirements:
|
99
|
+
- - ">="
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: '0'
|
102
|
+
requirements: []
|
103
|
+
rubyforge_project:
|
104
|
+
rubygems_version: 2.5.1
|
105
|
+
signing_key:
|
106
|
+
specification_version: 4
|
107
|
+
summary: Extend Zebra Datepicker with internationalization
|
108
|
+
test_files: []
|