intl_phone_picker 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -1
- data/README.md +7 -13
- data/config/locales/en.yml +0 -0
- data/config/locales/fr.yml +233 -0
- data/config/settings.yml +0 -0
- data/intl_phone_picker.gemspec +7 -7
- data/lib/intl_phone_picker/version.rb +1 -1
- data/vendor/assets/javascripts/intlTelInput_fr.js +19 -0
- data/vendor/assets/javascripts/intlTelInput_us.js +10 -0
- metadata +15 -10
- data/vendor/assets/javascripts/intl_phone_picker.js +0 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7f7efb11b4a4b954fe164477107269c44fd96dbf
|
4
|
+
data.tar.gz: fa34d85d2082b01f6d3416d787abe2a6052b196e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7e6026afd173ba67e5c87081f28a917c9af6e4d70cb08cbb7a6bac3a49953565bf27da77f8116e3d674a0fd7fb98fcfbdb2e76b560374f3d420bf0c7a39914f0
|
7
|
+
data.tar.gz: c078174342ec2a418c8a75e853825b19a9137ba2e28569454ce7c196e0442486c3a0fde8a2e3b650494c2629baf244051fe6805c28c506cac65f7ae9609b2371
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,12 @@
|
|
1
1
|
# Version 0.0.1
|
2
2
|
|
3
|
-
- Import javascript and css libraries
|
3
|
+
- Import javascript and css libraries.
|
4
|
+
|
5
|
+
# Version 0.0.2
|
6
|
+
|
7
|
+
- Change specifications
|
8
|
+
- Automatically import 'utils.js' and 'intl_phone_picker' when include javascript
|
9
|
+
- Add France (fr) to supported countries. Credits to Harold Simpson : https://github.com/harold-s/harold-s
|
10
|
+
- Include '//= require intlTelInput_fr' to use it.
|
11
|
+
- Include '//= require intlTelInput_us' to use default english number picker.
|
12
|
+
- Phone number picker is automatically added to all 'tel' fields.
|
data/README.md
CHANGED
@@ -1,15 +1,15 @@
|
|
1
|
+
# IntlPhonePicker
|
2
|
+
|
3
|
+
https://rubygems.org/gems/intl_phone_picker
|
4
|
+
|
5
|
+
IntlPhonePicker is a ruby gem which allow you to change your html5 "tel" fields into jQuery international phone number pickers.
|
6
|
+
|
1
7
|
## Sources
|
2
8
|
|
3
9
|
- Javascript based library : https://github.com/Bluefieldscom/intl-tel-input
|
4
10
|
- Ruby based gem : https://github.com/ispyropoulos/intl-tel-input-rails
|
5
11
|
- French language generator : https://github.com/harold-s/harold-s/tree/master/intl-tel-input-french-translation
|
6
12
|
|
7
|
-
# IntlPhonePicker
|
8
|
-
|
9
|
-
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/intl_phone_picker`. To experiment with that code, run `bin/console` for an interactive prompt.
|
10
|
-
|
11
|
-
TODO: Delete this and the text above, and describe your gem
|
12
|
-
|
13
13
|
## Installation
|
14
14
|
|
15
15
|
Add this line to your application's Gemfile:
|
@@ -37,13 +37,7 @@ To use javascript and stylesheet libraries you need to add :
|
|
37
37
|
- In application default javascript file :
|
38
38
|
|
39
39
|
```ruby
|
40
|
-
//= require
|
41
|
-
```
|
42
|
-
|
43
|
-
- If you want to enable it on all tel fields by default, add :
|
44
|
-
|
45
|
-
```ruby
|
46
|
-
//= require intl_phone_picker
|
40
|
+
//= require intlTelInput_[shortname_of_your_country]
|
47
41
|
```
|
48
42
|
|
49
43
|
## Usage
|
File without changes
|
@@ -0,0 +1,233 @@
|
|
1
|
+
af: "Afghanistan (افغانستان)"
|
2
|
+
al: "Albanie (Shqipëri)"
|
3
|
+
dz: "Algérie (الجزائر)"
|
4
|
+
as: "Samoa américaines (American Samoa)"
|
5
|
+
ad: "Andorre (Andorra)"
|
6
|
+
ao: "Angola"
|
7
|
+
ai: "Anguilla"
|
8
|
+
ag: "Antigua-et-Barbuda (Antigua and Barbuda)"
|
9
|
+
ar: "Argentine (Argentina)"
|
10
|
+
am: "Arménie (Հայաստան)"
|
11
|
+
aw: "Aruba"
|
12
|
+
au: "Australie (Australia)"
|
13
|
+
at: "Autriche (Österreich)"
|
14
|
+
az: "Azerbaïdjan (Azərbaycan)"
|
15
|
+
bs: "Bahamas"
|
16
|
+
bh: "Bahreïn (البحرين)"
|
17
|
+
bd: "Bangladesh (বাংলাদেশ)"
|
18
|
+
bb: "Barbade (Barbados)"
|
19
|
+
by: "Biélorussie (Беларусь)"
|
20
|
+
be: "Belgique (België)"
|
21
|
+
bz: "Belize"
|
22
|
+
bj: "Bénin"
|
23
|
+
bm: "Bermudes (Bermuda)"
|
24
|
+
bt: "Bhoutan (འབྲུག)"
|
25
|
+
bo: "Bolivie (Bolivia)"
|
26
|
+
ba: "Bosnie-Herzégovine (Босна и Херцеговина)"
|
27
|
+
bw: "Botswana"
|
28
|
+
br: "Brésil (Brasil)"
|
29
|
+
io: "Territoire britannique de l’océan Indien (British Indian Ocean Territory)"
|
30
|
+
vg: "Îles Vierges britanniques (British Virgin Islands)"
|
31
|
+
bn: "Brunei"
|
32
|
+
bg: "Bulgarie (България)"
|
33
|
+
bf: "Burkina Faso"
|
34
|
+
bi: "Burundi (Uburundi)"
|
35
|
+
kh: "Cambodge (កម្ពុជា)"
|
36
|
+
cm: "Cameroun"
|
37
|
+
ca: "Canada"
|
38
|
+
cv: "Cap-Vert (Kabu Verdi)"
|
39
|
+
bq: "Bonaire Saint-Eustache et Saba (Caribbean Netherlands)"
|
40
|
+
ky: "Îles Caïmans (Cay Islands)"
|
41
|
+
cf: "République centrafricaine"
|
42
|
+
td: "Tchad"
|
43
|
+
cl: "Chili (Chile)"
|
44
|
+
cn: "Chine (中国)"
|
45
|
+
co: "Colombie (Colombia)"
|
46
|
+
km: "Comores (جزر القمر)"
|
47
|
+
cd: "République démocratique du Congo (Jamhuri ya Kidemokrasia ya Kongo)"
|
48
|
+
cg: "République du Congo / (Congo) (Congo-Brazzaville)"
|
49
|
+
ck: "Îles Cook (Cook Islands)"
|
50
|
+
cr: "Costa Rica"
|
51
|
+
ci: "Côte d’Ivoire"
|
52
|
+
hr: "Croatie (Hrvatska)"
|
53
|
+
cu: "Cuba"
|
54
|
+
cw: "Curaçao"
|
55
|
+
cy: "Chypre (Κύπρος)"
|
56
|
+
cz: "République tchèque (Česká republika)"
|
57
|
+
dk: "Danemark (Danmark)"
|
58
|
+
dj: "Djibouti"
|
59
|
+
dm: "Dominique (Dominica)"
|
60
|
+
do: "République dominicaine (República Dominicana)"
|
61
|
+
ec: "Équateur (Ecuador)"
|
62
|
+
eg: "Égypte (مصر)"
|
63
|
+
sv: "Salvador (El Salvador)"
|
64
|
+
gq: "Guinée équatoriale (Guinea Ecuatorial)"
|
65
|
+
er: "Érythrée (Eritrea)"
|
66
|
+
ee: "Estonie (Eesti)"
|
67
|
+
et: "Éthiopie (Ethiopia)"
|
68
|
+
fk: "Îles Malouines (Islas Malvinas)"
|
69
|
+
fo: "Îles Féroé (Føroyar)"
|
70
|
+
fj: "Fidji (Fiji)"
|
71
|
+
fi: "Finlande (Suomi)"
|
72
|
+
fr: "France"
|
73
|
+
gf: "Guyane (Guyane française)"
|
74
|
+
pf: "Polynésie française"
|
75
|
+
ga: "Gabon"
|
76
|
+
gm: "Gambie (Gambia)"
|
77
|
+
ge: "Géorgie (საქართველო)"
|
78
|
+
de: "Allemagne (Deutschland)"
|
79
|
+
gh: "Ghana (Gaana)"
|
80
|
+
gi: "Gibraltar"
|
81
|
+
gr: "Grèce (Ελλάδα)"
|
82
|
+
gl: "Groenland (Kalaallit Nunaat)"
|
83
|
+
gd: "Grenade (Grenada)"
|
84
|
+
gp: "Guadeloupe"
|
85
|
+
gu: "Guam"
|
86
|
+
gt: "Guatemala"
|
87
|
+
gn: "Guinée"
|
88
|
+
gw: "Guinée-Bissau (República da Guiné-Bissau)"
|
89
|
+
gy: "Guyana"
|
90
|
+
ht: "Haïti (Haiti)"
|
91
|
+
hn: "Honduras"
|
92
|
+
hk: "Hong Kong (香港)"
|
93
|
+
hu: "Hongrie (Magyarország)"
|
94
|
+
is: "Islande (Ísland)"
|
95
|
+
in: "Inde (भारत)"
|
96
|
+
id: "Indonésie (Indonesia)"
|
97
|
+
ir: "Iran (ایران)"
|
98
|
+
iq: "Irak (العراق)"
|
99
|
+
ie: "Irlande (Ireland)"
|
100
|
+
il: "Israël (ישראל)"
|
101
|
+
it: "Italie (Italia)"
|
102
|
+
jm: "Jamaïque (Jamaica)"
|
103
|
+
jp: "Japon (日本)"
|
104
|
+
jo: "Jordanie (الأردن)"
|
105
|
+
kz: "Kazakhstan (Казахстан)"
|
106
|
+
ke: "Kenya"
|
107
|
+
ki: "Kiribati"
|
108
|
+
kw: "Koweït (الكويت)"
|
109
|
+
kg: "Kirghizistan (Кыргызстан)"
|
110
|
+
la: "Laos (ລາວ)"
|
111
|
+
lv: "Lettonie (Latvija)"
|
112
|
+
lb: "Liban (لبنان)"
|
113
|
+
ls: "Lesotho"
|
114
|
+
lr: "Liberia"
|
115
|
+
ly: "Libye (ليبيا)"
|
116
|
+
li: "Liechtenstein"
|
117
|
+
lt: "Lituanie (Lietuva)"
|
118
|
+
lu: "Luxembourg"
|
119
|
+
mo: "Macao (澳門)"
|
120
|
+
mk: "Macédoine (Македонија)"
|
121
|
+
mg: "Madagascar (Madagasikara)"
|
122
|
+
mw: "Malawi"
|
123
|
+
my: "Malaisie (Malaysia)"
|
124
|
+
mv: "Maldives"
|
125
|
+
ml: "Mali"
|
126
|
+
mt: "Malte (Malta)"
|
127
|
+
mh: "Marshall (Marshall Islands)"
|
128
|
+
mq: "Martinique"
|
129
|
+
mr: "Mauritanie (موريتانيا)"
|
130
|
+
mu: "Maurice (Moris)"
|
131
|
+
mx: "Mexique (México)"
|
132
|
+
fm: "Micronésie (Micronesia)"
|
133
|
+
md: "Moldavie (Republica Moldova)"
|
134
|
+
mc: "Monaco"
|
135
|
+
mn: "Mongolie (Монгол)"
|
136
|
+
me: "Monténégro (Crna Gora)"
|
137
|
+
ms: "Montserrat"
|
138
|
+
ma: "Maroc (المغرب)"
|
139
|
+
mz: "Mozambique (Moçambique)"
|
140
|
+
mm: "Birmanie (မြန်မာ)"
|
141
|
+
na: "Namibie (Namibië)"
|
142
|
+
nr: "Nauru"
|
143
|
+
np: "Népal (नेपाल)"
|
144
|
+
nl: "Pays-Bas (Nederland)"
|
145
|
+
nc: "Nouvelle-Calédonie"
|
146
|
+
nz: "Nouvelle-Zélande (New Zealand)"
|
147
|
+
ni: "Nicaragua"
|
148
|
+
ne: "Niger (Nijar)"
|
149
|
+
ng: "Nigeria"
|
150
|
+
nu: "Niue"
|
151
|
+
nf: "Île Norfolk (Norfolk Island)"
|
152
|
+
kp: "Corée du Nord (조선 민주주의 인민 공화국)"
|
153
|
+
mp: "Îles Mariannes du Nord (Northern Mariana Islands)"
|
154
|
+
no: "Norvège (Norge)"
|
155
|
+
om: "Oman (عُمان)"
|
156
|
+
pk: "Pakistan (پاکستان)"
|
157
|
+
pw: "Palaos (Palau)"
|
158
|
+
ps: "Autorité palestinienne (فلسطين)"
|
159
|
+
pa: "Panama (Panamá)"
|
160
|
+
pg: "Papouasie-Nouvelle-Guinée (Papua New Guinea)"
|
161
|
+
py: "Paraguay"
|
162
|
+
pe: "Pérou (Perú)"
|
163
|
+
ph: "Philippines"
|
164
|
+
pl: "Pologne (Polska)"
|
165
|
+
pt: "Portugal"
|
166
|
+
pr: "Porto Rico (Puerto Rico)"
|
167
|
+
qa: "Qatar (قطر)"
|
168
|
+
re: "La Réunion"
|
169
|
+
ro: "Roumanie (România)"
|
170
|
+
ru: "Russie (Россия)"
|
171
|
+
rw: "Rwanda"
|
172
|
+
bl: "Saint-Barthélemy"
|
173
|
+
sh: "Sainte-Hélène Ascension et Tristan da Cunha (Saint Helena)"
|
174
|
+
kn: "Saint-Christophe-et-Niévès (Saint Kitts and Nevis)"
|
175
|
+
lc: "Sainte-Lucie (Saint Lucia)"
|
176
|
+
mf: "Saint-Martin (Antilles françaises) (partie française))"
|
177
|
+
pm: "Saint-Pierre-et-Miquelon"
|
178
|
+
vc: "Saint-Vincent-et-les-Grenadines (Saint Vincent and the Grenadines)"
|
179
|
+
ws: "Samoa"
|
180
|
+
sm: "Saint-Marin (San Marino)"
|
181
|
+
st: "Sao Tomé-et-Principe (São Tomé e Príncipe)"
|
182
|
+
sa: "Arabie saoudite (المملكة العربية السعودية)"
|
183
|
+
sn: "Sénégal"
|
184
|
+
rs: "Serbie (Србија)"
|
185
|
+
sc: "Seychelles"
|
186
|
+
sl: "Sierra Leone"
|
187
|
+
sg: "Singapour (Singapore)"
|
188
|
+
sx: "Saint-Martin (Sint Maarten)"
|
189
|
+
sk: "Slovaquie (Slovensko)"
|
190
|
+
si: "Slovénie (Slovenija)"
|
191
|
+
sb: "Salomon (Solomon Islands)"
|
192
|
+
so: "Somalie (Soomaaliya)"
|
193
|
+
za: "Afrique du Sud (South Africa)"
|
194
|
+
kr: "Corée du Sud (대한민국)"
|
195
|
+
ss: "Soudan du Sud (جنوب السودان)"
|
196
|
+
es: "Espagne (España)"
|
197
|
+
lk: "Sri Lanka (ශ්රී ලංකාව)"
|
198
|
+
sd: "Soudan (السودان)"
|
199
|
+
sr: "Suriname"
|
200
|
+
sz: "Swaziland"
|
201
|
+
se: "Suède (Sverige)"
|
202
|
+
ch: "Suisse (Schweiz)"
|
203
|
+
sy: "Syrie (سوريا)"
|
204
|
+
tw: "Taïwan / (République de Chine (Taïwan)) (台灣)"
|
205
|
+
tj: "Tadjikistan (Tajikistan)"
|
206
|
+
tz: "Tanzanie (Tanzania)"
|
207
|
+
th: "Thaïlande (ไทย)"
|
208
|
+
tl: "Timor oriental (Timor-Leste)"
|
209
|
+
tg: "Togo"
|
210
|
+
tk: "Tokelau"
|
211
|
+
to: "Tonga"
|
212
|
+
tt: "Trinité-et-Tobago (Trinidad and Tobago)"
|
213
|
+
tn: "Tunisie (تونس)"
|
214
|
+
tr: "Turquie (Türkiye)"
|
215
|
+
tm: "Turkménistan (Turkmenistan)"
|
216
|
+
tc: "Îles Turques-et-Caïques (Turks and Caicos Islands)"
|
217
|
+
tv: "Tuvalu"
|
218
|
+
vi: "Îles Vierges des États-Unis (U.S. Virgin Islands)"
|
219
|
+
ug: "Ouganda (Uganda)"
|
220
|
+
ua: "Ukraine (Україна)"
|
221
|
+
ae: "Émirats arabes unis (الإمارات العربية المتحدة)"
|
222
|
+
gb: "Royaume-Uni (United Kingdom)"
|
223
|
+
us: "États-Unis (United States)"
|
224
|
+
uy: "Uruguay"
|
225
|
+
uz: "Ouzbékistan (Oʻzbekiston)"
|
226
|
+
vu: "Vanuatu"
|
227
|
+
va: "État de la Cité du Vatican (Città del Vaticano)"
|
228
|
+
ve: "Venezuela"
|
229
|
+
vn: "Viêt Nam (Việt Nam)"
|
230
|
+
wf: "Wallis-et-Futuna (Wallis and Futuna)"
|
231
|
+
ye: "Yémen (يمني)"
|
232
|
+
zm: "Zambie (Zambia)"
|
233
|
+
zw: "Zimbabwe"
|
data/config/settings.yml
ADDED
File without changes
|
data/intl_phone_picker.gemspec
CHANGED
@@ -5,17 +5,17 @@ require 'intl_phone_picker/version'
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |spec|
|
7
7
|
spec.name = "intl_phone_picker"
|
8
|
-
spec.version = "0.0.
|
8
|
+
spec.version = "0.0.2"
|
9
9
|
spec.authors = ["Fabien Dobat\n\n"]
|
10
|
-
spec.email = ["fabien.dobat@
|
10
|
+
spec.email = ["fabien.dobat@gmail.fr"]
|
11
11
|
|
12
12
|
if spec.respond_to?(:metadata)
|
13
|
-
#
|
13
|
+
# spec.metadata['allowed_push_host'] = "https://rubygems.org/gems/intl_phone_picker"
|
14
14
|
end
|
15
15
|
|
16
|
-
spec.summary = %q{
|
17
|
-
spec.description = %q{
|
18
|
-
|
16
|
+
spec.summary = %q{Internationalize your tel fields into jQuery numbers pickers}
|
17
|
+
spec.description = %q{IntlPhonePicker is a ruby gem which allow you to change your html5 "tel" fields into jQuery international phone number pickers.}
|
18
|
+
spec.homepage = "https://github.com/SeniorMedia/intl_phone_picker"
|
19
19
|
spec.license = "MIT"
|
20
20
|
|
21
21
|
spec.files = `git ls-files`.split("\n")
|
@@ -25,5 +25,5 @@ Gem::Specification.new do |spec|
|
|
25
25
|
|
26
26
|
spec.add_development_dependency "bundler", "~> 1.8"
|
27
27
|
spec.add_development_dependency "rake", "~> 10.0"
|
28
|
-
spec.add_dependency "railties", "
|
28
|
+
spec.add_dependency "railties", ">= 3.1"
|
29
29
|
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
//= require libphonenumber/utils
|
2
|
+
//= require intlTelInput
|
3
|
+
|
4
|
+
jQuery(document).ready(function($) {
|
5
|
+
|
6
|
+
var countryData = $.fn.intlTelInput.getCountryData();
|
7
|
+
|
8
|
+
// This line regroup all the countries from fr.yml
|
9
|
+
var hashCountryDataTranslation = {"af":"Afghanistan (افغانستان)","al":"Albanie (Shqipëri)","dz":"Algérie (الجزائر)","as":"Samoa américaines (American Samoa)","ad":"Andorre (Andorra)","ao":"Angola","ai":"Anguilla","ag":"Antigua-et-Barbuda (Antigua and Barbuda)","ar":"Argentine (Argentina)","am":"Arménie (Հայաստան)","aw":"Aruba","au":"Australie (Australia)","at":"Autriche (Österreich)","az":"Azerbaïdjan (Azərbaycan)","bs":"Bahamas","bh":"Bahreïn (البحرين)","bd":"Bangladesh (বাংলাদেশ)","bb":"Barbade (Barbados)","by":"Biélorussie (Беларусь)","be":"Belgique (België)","bz":"Belize","bj":"Bénin","bm":"Bermudes (Bermuda)","bt":"Bhoutan (འབྲུག)","bo":"Bolivie (Bolivia)","ba":"Bosnie-Herzégovine (Босна и Херцеговина)","bw":"Botswana","br":"Brésil (Brasil)","io":"Territoire britannique de l’océan Indien (British Indian Ocean Territory)","vg":"Îles Vierges britanniques (British Virgin Islands)","bn":"Brunei","bg":"Bulgarie (България)","bf":"Burkina Faso","bi":"Burundi (Uburundi)","kh":"Cambodge (កម្ពុជា)","cm":"Cameroun","ca":"Canada","cv":"Cap-Vert (Kabu Verdi)","bq":"Bonaire, Saint-Eustache et Saba (Caribbean Netherlands)","ky":"Îles Caïmans (Cay Islands)","cf":"République centrafricaine","td":"Tchad","cl":"Chili (Chile)","cn":"Chine (中国)","co":"Colombie (Colombia)","km":"Comores (جزر القمر)","cd":"République démocratique du Congo (Jamhuri ya Kidemokrasia ya Kongo)","cg":"République du Congo / (Congo) (Congo-Brazzaville)","ck":"Îles Cook (Cook Islands)","cr":"Costa Rica","ci":"Côte d’Ivoire","hr":"Croatie (Hrvatska)","cu":"Cuba","cw":"Curaçao","cy":"Chypre (Κύπρος)","cz":"République tchèque (Česká republika)","dk":"Danemark (Danmark)","dj":"Djibouti","dm":"Dominique (Dominica)","do":"République dominicaine (República Dominicana)","ec":"Équateur (Ecuador)","eg":"Égypte (مصر)","sv":"Salvador (El Salvador)","gq":"Guinée équatoriale (Guinea Ecuatorial)","er":"Érythrée (Eritrea)","ee":"Estonie (Eesti)","et":"Éthiopie (Ethiopia)","fk":"Îles Malouines (Islas Malvinas)","fo":"Îles Féroé (Føroyar)","fj":"Fidji (Fiji)","fi":"Finlande (Suomi)","fr":"France","gf":"Guyane (Guyane française)","pf":"Polynésie française","ga":"Gabon","gm":"Gambie (Gambia)","ge":"Géorgie (საქართველო)","de":"Allemagne (Deutschland)","gh":"Ghana (Gaana)","gi":"Gibraltar","gr":"Grèce (Ελλάδα)","gl":"Groenland (Kalaallit Nunaat)","gd":"Grenade (Grenada)","gp":"Guadeloupe","gu":"Guam","gt":"Guatemala","gn":"Guinée","gw":"Guinée-Bissau (República da Guiné-Bissau)","gy":"Guyana","ht":"Haïti (Haiti)","hn":"Honduras","hk":"Hong Kong (香港)","hu":"Hongrie (Magyarország)","is":"Islande (Ísland)","in":"Inde (भारत)","id":"Indonésie (Indonesia)","ir":"Iran (ایران)","iq":"Irak (العراق)","ie":"Irlande (Ireland)","il":"Israël (ישראל)","it":"Italie (Italia)","jm":"Jamaïque (Jamaica)","jp":"Japon (日本)","jo":"Jordanie (الأردن)","kz":"Kazakhstan (Казахстан)","ke":"Kenya","ki":"Kiribati","kw":"Koweït (الكويت)","kg":"Kirghizistan (Кыргызстан)","la":"Laos (ລາວ)","lv":"Lettonie (Latvija)","lb":"Liban (لبنان)","ls":"Lesotho","lr":"Liberia","ly":"Libye (ليبيا)","li":"Liechtenstein","lt":"Lituanie (Lietuva)","lu":"Luxembourg","mo":"Macao (澳門)","mk":"Macédoine (Македонија)","mg":"Madagascar (Madagasikara)","mw":"Malawi","my":"Malaisie (Malaysia)","mv":"Maldives","ml":"Mali","mt":"Malte (Malta)","mh":"Marshall (Marshall Islands)","mq":"Martinique","mr":"Mauritanie (موريتانيا)","mu":"Maurice (Moris)","mx":"Mexique (México)","fm":"Micronésie (Micronesia)","md":"Moldavie (Republica Moldova)","mc":"Monaco","mn":"Mongolie (Монгол)","me":"Monténégro (Crna Gora)","ms":"Montserrat","ma":"Maroc (المغرب)","mz":"Mozambique (Moçambique)","mm":"Birmanie (မြန်မာ)","na":"Namibie (Namibië)","nr":"Nauru","np":"Népal (नेपाल)","nl":"Pays-Bas (Nederland)","nc":"Nouvelle-Calédonie","nz":"Nouvelle-Zélande (New Zealand)","ni":"Nicaragua","ne":"Niger (Nijar)","ng":"Nigeria","nu":"Niue","nf":"Île Norfolk (Norfolk Island)","kp":"Corée du Nord (조선 민주주의 인민 공화국)","mp":"Îles Mariannes du Nord (Northern Mariana Islands)","no":"Norvège (Norge)","om":"Oman (عُمان)","pk":"Pakistan (پاکستان)","pw":"Palaos (Palau)","ps":"Autorité palestinienne (فلسطين)","pa":"Panama (Panamá)","pg":"Papouasie-Nouvelle-Guinée (Papua New Guinea)","py":"Paraguay","pe":"Pérou (Perú)","ph":"Philippines","pl":"Pologne (Polska)","pt":"Portugal","pr":"Porto Rico (Puerto Rico)","qa":"Qatar (قطر)","re":"La Réunion","ro":"Roumanie (România)","ru":"Russie (Россия)","rw":"Rwanda","bl":"Saint-Barthélemy","sh":"Sainte-Hélène, Ascension et Tristan da Cunha (Saint Helena)","kn":"Saint-Christophe-et-Niévès (Saint Kitts and Nevis)","lc":"Sainte-Lucie (Saint Lucia)","mf":"Saint-Martin (Antilles françaises) (partie française))","pm":"Saint-Pierre-et-Miquelon","vc":"Saint-Vincent-et-les-Grenadines (Saint Vincent and the Grenadines)","ws":"Samoa","sm":"Saint-Marin (San Marino)","st":"Sao Tomé-et-Principe (São Tomé e Príncipe)","sa":"Arabie saoudite (المملكة العربية السعودية)","sn":"Sénégal","rs":"Serbie (Србија)","sc":"Seychelles","sl":"Sierra Leone","sg":"Singapour (Singapore)","sx":"Saint-Martin (Sint Maarten)","sk":"Slovaquie (Slovensko)","si":"Slovénie (Slovenija)","sb":"Salomon (Solomon Islands)","so":"Somalie (Soomaaliya)","za":"Afrique du Sud (South Africa)","kr":"Corée du Sud (대한민국)","ss":"Soudan du Sud (جنوب السودان)","es":"Espagne (España)","lk":"Sri Lanka (ශ්රී ලංකාව)","sd":"Soudan (السودان)","sr":"Suriname","sz":"Swaziland","se":"Suède (Sverige)","ch":"Suisse (Schweiz)","sy":"Syrie (سوريا)","tw":"Taïwan / (République de Chine (Taïwan)) (台灣)","tj":"Tadjikistan (Tajikistan)","tz":"Tanzanie (Tanzania)","th":"Thaïlande (ไทย)","tl":"Timor oriental (Timor-Leste)","tg":"Togo","tk":"Tokelau","to":"Tonga","tt":"Trinité-et-Tobago (Trinidad and Tobago)","tn":"Tunisie (تونس)","tr":"Turquie (Türkiye)","tm":"Turkménistan (Turkmenistan)","tc":"Îles Turques-et-Caïques (Turks and Caicos Islands)","tv":"Tuvalu","vi":"Îles Vierges des États-Unis (U.S. Virgin Islands)","ug":"Ouganda (Uganda)","ua":"Ukraine (Україна)","ae":"Émirats arabes unis (الإمارات العربية المتحدة)","gb":"Royaume-Uni (United Kingdom)","us":"États-Unis (United States)","uy":"Uruguay","uz":"Ouzbékistan (Oʻzbekiston)","vu":"Vanuatu","va":"État de la Cité du Vatican (Città del Vaticano)","ve":"Venezuela","vn":"Viêt Nam (Việt Nam)","wf":"Wallis-et-Futuna (Wallis and Futuna)","ye":"Yémen (اليمن)","zm":"Zambie (Zambia)","zw":"Zimbabwe"};
|
10
|
+
$.each(countryData, function(i, country) {
|
11
|
+
country.name = hashCountryDataTranslation[country.iso2];
|
12
|
+
});
|
13
|
+
|
14
|
+
$("input[type=tel]").intlTelInput({
|
15
|
+
defaultCountry: "fr",
|
16
|
+
preferredCountries: ['fr', 'be', 'ch', 'lu', 'ca', 'mc'],
|
17
|
+
});
|
18
|
+
|
19
|
+
});
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: intl_phone_picker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- |+
|
@@ -44,19 +44,20 @@ dependencies:
|
|
44
44
|
name: railties
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
|
-
- - "
|
47
|
+
- - ">="
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version:
|
49
|
+
version: '3.1'
|
50
50
|
type: :runtime
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
|
-
- - "
|
54
|
+
- - ">="
|
55
55
|
- !ruby/object:Gem::Version
|
56
|
-
version:
|
57
|
-
description:
|
56
|
+
version: '3.1'
|
57
|
+
description: IntlPhonePicker is a ruby gem which allow you to change your html5 "tel"
|
58
|
+
fields into jQuery international phone number pickers.
|
58
59
|
email:
|
59
|
-
- fabien.dobat@
|
60
|
+
- fabien.dobat@gmail.fr
|
60
61
|
executables: []
|
61
62
|
extensions: []
|
62
63
|
extra_rdoc_files: []
|
@@ -69,15 +70,19 @@ files:
|
|
69
70
|
- Rakefile
|
70
71
|
- bin/console
|
71
72
|
- bin/setup
|
73
|
+
- config/locales/en.yml
|
74
|
+
- config/locales/fr.yml
|
75
|
+
- config/settings.yml
|
72
76
|
- intl_phone_picker.gemspec
|
73
77
|
- lib/intl_phone_picker.rb
|
74
78
|
- lib/intl_phone_picker/version.rb
|
75
79
|
- vendor/assets/images/flags.png
|
76
80
|
- vendor/assets/javascripts/intlTelInput.js
|
77
|
-
- vendor/assets/javascripts/
|
81
|
+
- vendor/assets/javascripts/intlTelInput_fr.js
|
82
|
+
- vendor/assets/javascripts/intlTelInput_us.js
|
78
83
|
- vendor/assets/javascripts/libphonenumber/utils.js
|
79
84
|
- vendor/assets/stylesheets/intlTelInput.css
|
80
|
-
homepage:
|
85
|
+
homepage: https://github.com/SeniorMedia/intl_phone_picker
|
81
86
|
licenses:
|
82
87
|
- MIT
|
83
88
|
metadata: {}
|
@@ -100,5 +105,5 @@ rubyforge_project:
|
|
100
105
|
rubygems_version: 2.4.6
|
101
106
|
signing_key:
|
102
107
|
specification_version: 4
|
103
|
-
summary:
|
108
|
+
summary: Internationalize your tel fields into jQuery numbers pickers
|
104
109
|
test_files: []
|