devise-i18n-bootstrap 0.3.0.beta

Sign up to get free protection for your applications and to get access to all the features.
Files changed (45) hide show
  1. checksums.yaml +7 -0
  2. data/.document +5 -0
  3. data/.project +12 -0
  4. data/.rspec +1 -0
  5. data/Gemfile +9 -0
  6. data/LICENSE.txt +20 -0
  7. data/README.md +55 -0
  8. data/Rakefile +30 -0
  9. data/VERSION +1 -0
  10. data/app/views/devise/_links.erb +3 -0
  11. data/app/views/devise/confirmations/new.html.erb +12 -0
  12. data/app/views/devise/mailer/confirmation_instructions.html.erb +6 -0
  13. data/app/views/devise/mailer/reset_password_instructions.html.erb +8 -0
  14. data/app/views/devise/mailer/unlock_instructions.html.erb +7 -0
  15. data/app/views/devise/passwords/edit.html.erb +16 -0
  16. data/app/views/devise/passwords/new.html.erb +12 -0
  17. data/app/views/devise/registrations/edit.html.erb +25 -0
  18. data/app/views/devise/registrations/new.html.erb +18 -0
  19. data/app/views/devise/sessions/new.html.erb +17 -0
  20. data/app/views/devise/shared/_links.erb +25 -0
  21. data/app/views/devise/unlocks/new.html.erb +12 -0
  22. data/config/locales/bg.yml +101 -0
  23. data/config/locales/ca.yml +59 -0
  24. data/config/locales/de.yml +113 -0
  25. data/config/locales/en.yml +110 -0
  26. data/config/locales/es-AR.yml +51 -0
  27. data/config/locales/es-ES.yml +59 -0
  28. data/config/locales/es.yml +51 -0
  29. data/config/locales/fr.yml +51 -0
  30. data/config/locales/hu.yml +59 -0
  31. data/config/locales/it.yml +51 -0
  32. data/config/locales/nl.yml +59 -0
  33. data/config/locales/pl.yml +57 -0
  34. data/config/locales/pt-BR.yml +51 -0
  35. data/config/locales/ru.yml +56 -0
  36. data/config/locales/tr.yml +51 -0
  37. data/config/locales/zh-CN.yml +57 -0
  38. data/config/locales/zh-TW.yml +57 -0
  39. data/devise-i18n-bootstrap.gemspec +95 -0
  40. data/lib/devise-i18n-bootstrap.rb +23 -0
  41. data/lib/generators/devise/views/i18n_templates/i18n_templates_generator.rb +10 -0
  42. data/lib/generators/devise/views/locale/locale_generator.rb +10 -0
  43. data/spec/devise-i18n-bootstrap_spec.rb +8 -0
  44. data/spec/spec_helper.rb +3 -0
  45. metadata +159 -0
@@ -0,0 +1,57 @@
1
+ zh-CN:
2
+ devise:
3
+ confirmations:
4
+ new:
5
+ resend_confirmation_instructions: 重新发送确认指示
6
+ mailer:
7
+ confirmation_instructions:
8
+ action: 确认我的帐户
9
+ greeting: 欢迎 %{recipient}!
10
+ instruction: ! '您可以通过下面的链接确认您的帐户的电子邮件:'
11
+ subject: 确认指示
12
+ reset_password_instructions:
13
+ action: 更改我的密码
14
+ greeting: 你好 %{recipient}!
15
+ instruction: 有人要求更改密码的链接,并通过下面的链接,你可以做到这一点。
16
+ instruction_2: 如果你没有要求,请忽略此电子邮件。
17
+ instruction_3: 您的密码将不会改变,直到你访问上面的链接,并创建一个新的。
18
+ subject: 重设密码的说明
19
+ unlock_instructions:
20
+ action: 帐户解锁
21
+ greeting: 你好 %{recipient}!
22
+ instruction: ! '点击下面的链接到您的帐户解锁:'
23
+ message: 您的帐户已被锁定由于过量的不成功的登录尝试。
24
+ subject: 解锁说明
25
+ passwords:
26
+ new:
27
+ forgot_your_password: 忘记密码?
28
+ send_me_reset_password_instructions: 给我发送重设密码的说明
29
+ edit:
30
+ change_your_password: 更改您的密码
31
+ new_password: 新密码
32
+ confirm_new_password: 确认新密码
33
+ change_my_password: 更改我的密码
34
+ registrations:
35
+ edit:
36
+ are_you_sure: 你确定吗?
37
+ cancel_my_account: 取消我的帐户
38
+ leave_blank_if_you_don_t_want_to_change_it: 你不想去改变它,不需要填写
39
+ title: 修改 %{resource}
40
+ we_need_your_current_password_to_confirm_your_changes: 我们需要您的当前密码以确认您的更改
41
+ update: 更新
42
+ new:
43
+ sign_up: 注册
44
+ sessions:
45
+ new:
46
+ sign_in: 登录
47
+ shared:
48
+ links:
49
+ didn_t_receive_confirmation_instructions: 没有收到确认指令?
50
+ didn_t_receive_unlock_instructions: 没有收到解锁指令?
51
+ forgot_your_password: 忘记密码?
52
+ sign_in: 登录
53
+ sign_in_with_provider: 用 %{provider} 登录
54
+ sign_up: 注册
55
+ unlocks:
56
+ new:
57
+ resend_unlock_instructions: 重发解锁指示
@@ -0,0 +1,57 @@
1
+ zh-TW:
2
+ devise:
3
+ confirmations:
4
+ new:
5
+ resend_confirmation_instructions: '重新發送確認信'
6
+ mailer:
7
+ confirmation_instructions:
8
+ action: '確認帳號'
9
+ greeting: '%{recipient} 你好!'
10
+ instruction: ! '您可以利用下面的連結確認您的帳戶的電子郵件:'
11
+ subject: '確認帳號的說明'
12
+ reset_password_instructions:
13
+ action: '更改我的密碼'
14
+ greeting: '你好 %{recipient}!'
15
+ instruction: '有人要求更改密碼的連結,你可以利用下面的連結更改密碼。'
16
+ instruction_2: '如果你沒有要求,請忽略此電子郵件。'
17
+ instruction_3: '如果你沒有進入上面的連結,並建立新的密碼,你的密碼不會被改變。'
18
+ subject: '重設密碼的說明'
19
+ unlock_instructions:
20
+ action: '帳戶解鎖'
21
+ greeting: '你好 %{recipient}!'
22
+ instruction: ! '點擊下面的連結到您的帳戶進行解鎖:'
23
+ message: '由於多次的不成功的登入嘗試,您的帳戶已被鎖定。'
24
+ subject: '帳戶解鎖說明'
25
+ passwords:
26
+ new:
27
+ forgot_your_password: '忘記密碼?'
28
+ send_me_reset_password_instructions: '請寄重設密碼的說明信件給我'
29
+ edit:
30
+ change_your_password: '更改您的密碼'
31
+ new_password: '新密碼'
32
+ confirm_new_password: '確認新密碼'
33
+ change_my_password: '更改我的密碼'
34
+ registrations:
35
+ edit:
36
+ are_you_sure: '你確定嗎?'
37
+ cancel_my_account: '取消我的帳戶'
38
+ leave_blank_if_you_don_t_want_to_change_it: '不想修改的話就不需要填寫這個欄位'
39
+ title: '修改 %{resource}'
40
+ we_need_your_current_password_to_confirm_your_changes: '我們需要您的目前的密碼以確認您的更改'
41
+ update: '更新'
42
+ new:
43
+ sign_up: '註冊'
44
+ sessions:
45
+ new:
46
+ sign_in: '登入'
47
+ shared:
48
+ links:
49
+ didn_t_receive_confirmation_instructions: '沒有收到確認信件?'
50
+ didn_t_receive_unlock_instructions: '沒有收到解鎖信件?'
51
+ forgot_your_password: '忘記密碼?'
52
+ sign_in: '登入'
53
+ sign_in_with_provider: '用 %{provider} 登入'
54
+ sign_up: '註冊'
55
+ unlocks:
56
+ new:
57
+ resend_unlock_instructions: '重發解鎖說明信件'
@@ -0,0 +1,95 @@
1
+ # Generated by jeweler
2
+ # DO NOT EDIT THIS FILE DIRECTLY
3
+ # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
+ # -*- encoding: utf-8 -*-
5
+ # stub: devise-i18n-bootstrap 0.3.0.beta ruby lib
6
+
7
+ Gem::Specification.new do |s|
8
+ s.name = "devise-i18n-bootstrap"
9
+ s.version = "0.3.0.beta"
10
+
11
+ s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
12
+ s.require_paths = ["lib"]
13
+ s.authors = ["mcasimir", "Jozsef Nyitrai"]
14
+ s.date = "2014-05-21"
15
+ s.description = "I18n support for devise views based on Twitter Bootstrap 3"
16
+ s.email = "nyitrai@maximalink.com"
17
+ s.extra_rdoc_files = [
18
+ "LICENSE.txt",
19
+ "README.md"
20
+ ]
21
+ s.files = [
22
+ ".document",
23
+ ".project",
24
+ ".rspec",
25
+ "Gemfile",
26
+ "LICENSE.txt",
27
+ "README.md",
28
+ "Rakefile",
29
+ "VERSION",
30
+ "app/views/devise/_links.erb",
31
+ "app/views/devise/confirmations/new.html.erb",
32
+ "app/views/devise/mailer/confirmation_instructions.html.erb",
33
+ "app/views/devise/mailer/reset_password_instructions.html.erb",
34
+ "app/views/devise/mailer/unlock_instructions.html.erb",
35
+ "app/views/devise/passwords/edit.html.erb",
36
+ "app/views/devise/passwords/new.html.erb",
37
+ "app/views/devise/registrations/edit.html.erb",
38
+ "app/views/devise/registrations/new.html.erb",
39
+ "app/views/devise/sessions/new.html.erb",
40
+ "app/views/devise/shared/_links.erb",
41
+ "app/views/devise/unlocks/new.html.erb",
42
+ "config/locales/bg.yml",
43
+ "config/locales/ca.yml",
44
+ "config/locales/de.yml",
45
+ "config/locales/en.yml",
46
+ "config/locales/es-AR.yml",
47
+ "config/locales/es-ES.yml",
48
+ "config/locales/es.yml",
49
+ "config/locales/fr.yml",
50
+ "config/locales/hu.yml",
51
+ "config/locales/it.yml",
52
+ "config/locales/nl.yml",
53
+ "config/locales/pl.yml",
54
+ "config/locales/pt-BR.yml",
55
+ "config/locales/ru.yml",
56
+ "config/locales/tr.yml",
57
+ "config/locales/zh-CN.yml",
58
+ "config/locales/zh-TW.yml",
59
+ "devise-i18n-bootstrap.gemspec",
60
+ "lib/devise-i18n-bootstrap.rb",
61
+ "lib/generators/devise/views/i18n_templates/i18n_templates_generator.rb",
62
+ "lib/generators/devise/views/locale/locale_generator.rb",
63
+ "spec/devise-i18n-bootstrap_spec.rb",
64
+ "spec/spec_helper.rb"
65
+ ]
66
+ s.homepage = "http://github.com/maximalink/devise-i18n-bootstrap"
67
+ s.licenses = ["MIT"]
68
+ s.rubygems_version = "2.2.2"
69
+ s.summary = "I18n support for devise views based on Twitter Bootstrap 3"
70
+
71
+ if s.respond_to? :specification_version then
72
+ s.specification_version = 4
73
+
74
+ if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
75
+ s.add_development_dependency(%q<rspec>, [">= 2.4.0"])
76
+ s.add_development_dependency(%q<bundler>, [">= 0"])
77
+ s.add_development_dependency(%q<jeweler>, ["~> 1.8.3"])
78
+ s.add_development_dependency(%q<i18n-spec>, [">= 0"])
79
+ s.add_development_dependency(%q<localeapp>, [">= 0"])
80
+ else
81
+ s.add_dependency(%q<rspec>, [">= 2.4.0"])
82
+ s.add_dependency(%q<bundler>, [">= 0"])
83
+ s.add_dependency(%q<jeweler>, ["~> 1.8.3"])
84
+ s.add_dependency(%q<i18n-spec>, [">= 0"])
85
+ s.add_dependency(%q<localeapp>, [">= 0"])
86
+ end
87
+ else
88
+ s.add_dependency(%q<rspec>, [">= 2.4.0"])
89
+ s.add_dependency(%q<bundler>, [">= 0"])
90
+ s.add_dependency(%q<jeweler>, ["~> 1.8.3"])
91
+ s.add_dependency(%q<i18n-spec>, [">= 0"])
92
+ s.add_dependency(%q<localeapp>, [">= 0"])
93
+ end
94
+ end
95
+
@@ -0,0 +1,23 @@
1
+ require 'rails'
2
+ module DeviseI18nViews
3
+ class Engine < ::Rails::Engine
4
+ end
5
+
6
+ class Railtie < ::Rails::Railtie #:nodoc:
7
+ initializer 'rails-i18n-views' do |app|
8
+ DeviseI18nViews::Railtie.instance_eval do
9
+ pattern = pattern_from app.config.i18n.available_locales
10
+
11
+ files = Dir[File.join(File.dirname(__FILE__), '../locales', "#{pattern}.yml")]
12
+ I18n.load_path.concat(files)
13
+ end
14
+ end
15
+
16
+ protected
17
+
18
+ def self.pattern_from(args)
19
+ array = Array(args || [])
20
+ array.blank? ? '*' : "{#{array.join ','}}"
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,10 @@
1
+ module Devise
2
+ module Views
3
+ class I18nTemplatesGenerator < Rails::Generators::Base
4
+ source_root File.expand_path('../../../../../../app/views', __FILE__)
5
+ def copy_views
6
+ directory("devise", File.join("app", "views", "devise"))
7
+ end
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,10 @@
1
+ module Devise
2
+ module Views
3
+ class LocaleGenerator < Rails::Generators::NamedBase
4
+ source_root File.expand_path('../../../../../../config/locales', __FILE__)
5
+ def copy_locale
6
+ copy_file("#{name}.yml", File.join('config', 'locales', "devise.views.#{name}.yml"))
7
+ end
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,8 @@
1
+ require 'spec_helper'
2
+
3
+ Dir.glob('config/locales/*.yml').each do |locale_file|
4
+ describe "a devise-i18n-bootstrap #{locale_file} locale file" do
5
+ it_behaves_like 'a valid locale file', locale_file
6
+ it { locale_file.should be_a_subset_of 'config/locales/en.yml' }
7
+ end
8
+ end
@@ -0,0 +1,3 @@
1
+ require 'rspec'
2
+ require 'yaml' unless defined?(YAML)
3
+ require 'i18n-spec'
metadata ADDED
@@ -0,0 +1,159 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: devise-i18n-bootstrap
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.3.0.beta
5
+ platform: ruby
6
+ authors:
7
+ - mcasimir
8
+ - Jozsef Nyitrai
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2014-05-21 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: rspec
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - ">="
19
+ - !ruby/object:Gem::Version
20
+ version: 2.4.0
21
+ type: :development
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - ">="
26
+ - !ruby/object:Gem::Version
27
+ version: 2.4.0
28
+ - !ruby/object:Gem::Dependency
29
+ name: bundler
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: '0'
35
+ type: :development
36
+ prerelease: false
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - ">="
40
+ - !ruby/object:Gem::Version
41
+ version: '0'
42
+ - !ruby/object:Gem::Dependency
43
+ name: jeweler
44
+ requirement: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - "~>"
47
+ - !ruby/object:Gem::Version
48
+ version: 1.8.3
49
+ type: :development
50
+ prerelease: false
51
+ version_requirements: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - "~>"
54
+ - !ruby/object:Gem::Version
55
+ version: 1.8.3
56
+ - !ruby/object:Gem::Dependency
57
+ name: i18n-spec
58
+ requirement: !ruby/object:Gem::Requirement
59
+ requirements:
60
+ - - ">="
61
+ - !ruby/object:Gem::Version
62
+ version: '0'
63
+ type: :development
64
+ prerelease: false
65
+ version_requirements: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - ">="
68
+ - !ruby/object:Gem::Version
69
+ version: '0'
70
+ - !ruby/object:Gem::Dependency
71
+ name: localeapp
72
+ requirement: !ruby/object:Gem::Requirement
73
+ requirements:
74
+ - - ">="
75
+ - !ruby/object:Gem::Version
76
+ version: '0'
77
+ type: :development
78
+ prerelease: false
79
+ version_requirements: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - ">="
82
+ - !ruby/object:Gem::Version
83
+ version: '0'
84
+ description: I18n support for devise views based on Twitter Bootstrap 3
85
+ email: nyitrai@maximalink.com
86
+ executables: []
87
+ extensions: []
88
+ extra_rdoc_files:
89
+ - LICENSE.txt
90
+ - README.md
91
+ files:
92
+ - ".document"
93
+ - ".project"
94
+ - ".rspec"
95
+ - Gemfile
96
+ - LICENSE.txt
97
+ - README.md
98
+ - Rakefile
99
+ - VERSION
100
+ - app/views/devise/_links.erb
101
+ - app/views/devise/confirmations/new.html.erb
102
+ - app/views/devise/mailer/confirmation_instructions.html.erb
103
+ - app/views/devise/mailer/reset_password_instructions.html.erb
104
+ - app/views/devise/mailer/unlock_instructions.html.erb
105
+ - app/views/devise/passwords/edit.html.erb
106
+ - app/views/devise/passwords/new.html.erb
107
+ - app/views/devise/registrations/edit.html.erb
108
+ - app/views/devise/registrations/new.html.erb
109
+ - app/views/devise/sessions/new.html.erb
110
+ - app/views/devise/shared/_links.erb
111
+ - app/views/devise/unlocks/new.html.erb
112
+ - config/locales/bg.yml
113
+ - config/locales/ca.yml
114
+ - config/locales/de.yml
115
+ - config/locales/en.yml
116
+ - config/locales/es-AR.yml
117
+ - config/locales/es-ES.yml
118
+ - config/locales/es.yml
119
+ - config/locales/fr.yml
120
+ - config/locales/hu.yml
121
+ - config/locales/it.yml
122
+ - config/locales/nl.yml
123
+ - config/locales/pl.yml
124
+ - config/locales/pt-BR.yml
125
+ - config/locales/ru.yml
126
+ - config/locales/tr.yml
127
+ - config/locales/zh-CN.yml
128
+ - config/locales/zh-TW.yml
129
+ - devise-i18n-bootstrap.gemspec
130
+ - lib/devise-i18n-bootstrap.rb
131
+ - lib/generators/devise/views/i18n_templates/i18n_templates_generator.rb
132
+ - lib/generators/devise/views/locale/locale_generator.rb
133
+ - spec/devise-i18n-bootstrap_spec.rb
134
+ - spec/spec_helper.rb
135
+ homepage: http://github.com/maximalink/devise-i18n-bootstrap
136
+ licenses:
137
+ - MIT
138
+ metadata: {}
139
+ post_install_message:
140
+ rdoc_options: []
141
+ require_paths:
142
+ - lib
143
+ required_ruby_version: !ruby/object:Gem::Requirement
144
+ requirements:
145
+ - - ">="
146
+ - !ruby/object:Gem::Version
147
+ version: '0'
148
+ required_rubygems_version: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - ">"
151
+ - !ruby/object:Gem::Version
152
+ version: 1.3.1
153
+ requirements: []
154
+ rubyforge_project:
155
+ rubygems_version: 2.2.2
156
+ signing_key:
157
+ specification_version: 4
158
+ summary: I18n support for devise views based on Twitter Bootstrap 3
159
+ test_files: []