From 5cfa6d2f141b9bde52a6ba0919f7429148b6e1d9 Mon Sep 17 00:00:00 2001 From: Malka Rivka Atkins Date: Tue, 28 Aug 2018 20:55:20 -0500 Subject: [PATCH] Add users --- .DS_Store | Bin 0 -> 8196 bytes .gitignore | 30 ++ .ruby-version | 1 + Gemfile | 69 +++++ Gemfile.lock | 277 +++++++++++++++++ Guardfile | 81 +++++ README.md | 1 + Rakefile | 6 + app/.DS_Store | Bin 0 -> 8196 bytes app/assets/.DS_Store | Bin 0 -> 8196 bytes app/assets/config/.DS_Store | Bin 0 -> 6148 bytes app/assets/config/manifest.js | 3 + app/assets/images/.keep | 0 app/assets/javascripts/.DS_Store | Bin 0 -> 6148 bytes app/assets/javascripts/application.js | 16 + app/assets/javascripts/cable.js | 13 + app/assets/javascripts/channels/.keep | 0 app/assets/javascripts/users.coffee | 3 + app/assets/stylesheets/.DS_Store | Bin 0 -> 6148 bytes app/assets/stylesheets/application.css | 24 ++ app/assets/stylesheets/users.scss | 3 + app/channels/application_cable/channel.rb | 4 + app/channels/application_cable/connection.rb | 4 + app/controllers/.DS_Store | Bin 0 -> 6148 bytes app/controllers/application_controller.rb | 18 ++ app/controllers/concerns/.keep | 0 app/controllers/users_controller.rb | 16 + app/helpers/application_helper.rb | 2 + app/helpers/users_helper.rb | 2 + app/jobs/application_job.rb | 2 + app/mailers/application_mailer.rb | 4 + app/models/application_record.rb | 3 + app/models/concerns/.keep | 0 app/models/user.rb | 9 + app/views/.DS_Store | Bin 0 -> 6148 bytes app/views/devise/.DS_Store | Bin 0 -> 8196 bytes app/views/devise/confirmations/new.html.erb | 16 + .../mailer/confirmation_instructions.html.erb | 5 + .../devise/mailer/email_changed.html.erb | 7 + .../devise/mailer/password_change.html.erb | 3 + .../reset_password_instructions.html.erb | 8 + .../mailer/unlock_instructions.html.erb | 7 + app/views/devise/passwords/.DS_Store | Bin 0 -> 6148 bytes app/views/devise/passwords/edit.html.erb | 25 ++ app/views/devise/passwords/new.html.erb | 16 + app/views/devise/registrations/.DS_Store | Bin 0 -> 6148 bytes app/views/devise/registrations/edit.html.erb | 60 ++++ app/views/devise/registrations/new.html.erb | 44 +++ app/views/devise/sessions/.DS_Store | Bin 0 -> 6148 bytes app/views/devise/sessions/_new.html.erb | 17 ++ app/views/devise/sessions/new.html.erb | 20 ++ app/views/devise/shared/.DS_Store | Bin 0 -> 6148 bytes app/views/devise/shared/_links.html.erb | 25 ++ app/views/devise/unlocks/new.html.erb | 16 + app/views/layouts/.DS_Store | Bin 0 -> 6148 bytes app/views/layouts/_header.html.erb | 23 ++ app/views/layouts/application.html.erb | 18 ++ app/views/layouts/mailer.html.erb | 13 + app/views/layouts/mailer.text.erb | 1 + app/views/users/_user.html.erb | 5 + app/views/users/index.html.erb | 5 + app/views/users/show.html.erb | 7 + bin/bundle | 3 + bin/rails | 9 + bin/rake | 9 + bin/setup | 36 +++ bin/spring | 17 ++ bin/update | 31 ++ bin/yarn | 11 + config.ru | 5 + config/.DS_Store | Bin 0 -> 8196 bytes config/application.rb | 19 ++ config/boot.rb | 4 + config/cable.yml | 10 + config/credentials.yml.enc | 1 + config/database.yml | 85 ++++++ config/environment.rb | 5 + config/environments/.DS_Store | Bin 0 -> 6148 bytes config/environments/development.rb | 66 ++++ config/environments/production.rb | 96 ++++++ config/environments/test.rb | 48 +++ config/initializers/.DS_Store | Bin 0 -> 6148 bytes .../application_controller_renderer.rb | 8 + config/initializers/assets.rb | 14 + config/initializers/backtrace_silencers.rb | 7 + .../initializers/content_security_policy.rb | 25 ++ config/initializers/cookies_serializer.rb | 5 + config/initializers/devise.rb | 283 ++++++++++++++++++ .../initializers/filter_parameter_logging.rb | 4 + config/initializers/inflections.rb | 16 + config/initializers/mime_types.rb | 4 + config/initializers/wrap_parameters.rb | 14 + config/locales/devise.en.yml | 64 ++++ config/locales/en.yml | 33 ++ config/puma.rb | 34 +++ config/routes.rb | 7 + config/spring.rb | 6 + config/storage.yml | 34 +++ db/.DS_Store | Bin 0 -> 6148 bytes db/migrate/.DS_Store | Bin 0 -> 6148 bytes .../20180815235126_devise_create_users.rb | 48 +++ db/schema.rb | 39 +++ db/seeds.rb | 7 + lib/assets/.keep | 0 lib/tasks/.keep | 0 log/.keep | 0 package.json | 5 + public/404.html | 67 +++++ public/422.html | 67 +++++ public/500.html | 66 ++++ public/apple-touch-icon-precomposed.png | 0 public/apple-touch-icon.png | 0 public/favicon.ico | 0 public/robots.txt | 1 + storage/.keep | 0 test/.DS_Store | Bin 0 -> 10244 bytes test/application_system_test_case.rb | 5 + test/controllers/.DS_Store | Bin 0 -> 6148 bytes test/controllers/.keep | 0 test/controllers/users_controller_test.rb | 14 + test/fixtures/.DS_Store | Bin 0 -> 6148 bytes test/fixtures/.keep | 0 test/fixtures/files/.keep | 0 test/fixtures/users.yml | 11 + test/helpers/.keep | 0 test/integration/.DS_Store | Bin 0 -> 6148 bytes test/integration/.keep | 0 test/integration/user_signup_test.rb | 35 +++ test/mailers/.keep | 0 test/models/.DS_Store | Bin 0 -> 6148 bytes test/models/.keep | 0 test/models/user_test.rb | 7 + test/system/.keep | 0 test/test_helper.rb | 10 + tmp/.keep | 0 vendor/.keep | 0 136 files changed, 2327 insertions(+) create mode 100644 .DS_Store create mode 100644 .gitignore create mode 100644 .ruby-version create mode 100644 Gemfile create mode 100644 Gemfile.lock create mode 100644 Guardfile create mode 100644 README.md create mode 100644 Rakefile create mode 100644 app/.DS_Store create mode 100644 app/assets/.DS_Store create mode 100644 app/assets/config/.DS_Store create mode 100644 app/assets/config/manifest.js create mode 100644 app/assets/images/.keep create mode 100644 app/assets/javascripts/.DS_Store create mode 100644 app/assets/javascripts/application.js create mode 100644 app/assets/javascripts/cable.js create mode 100644 app/assets/javascripts/channels/.keep create mode 100644 app/assets/javascripts/users.coffee create mode 100644 app/assets/stylesheets/.DS_Store create mode 100644 app/assets/stylesheets/application.css create mode 100644 app/assets/stylesheets/users.scss create mode 100644 app/channels/application_cable/channel.rb create mode 100644 app/channels/application_cable/connection.rb create mode 100644 app/controllers/.DS_Store create mode 100644 app/controllers/application_controller.rb create mode 100644 app/controllers/concerns/.keep create mode 100644 app/controllers/users_controller.rb create mode 100644 app/helpers/application_helper.rb create mode 100644 app/helpers/users_helper.rb create mode 100644 app/jobs/application_job.rb create mode 100644 app/mailers/application_mailer.rb create mode 100644 app/models/application_record.rb create mode 100644 app/models/concerns/.keep create mode 100644 app/models/user.rb create mode 100644 app/views/.DS_Store create mode 100644 app/views/devise/.DS_Store create mode 100644 app/views/devise/confirmations/new.html.erb create mode 100644 app/views/devise/mailer/confirmation_instructions.html.erb create mode 100644 app/views/devise/mailer/email_changed.html.erb create mode 100644 app/views/devise/mailer/password_change.html.erb create mode 100644 app/views/devise/mailer/reset_password_instructions.html.erb create mode 100644 app/views/devise/mailer/unlock_instructions.html.erb create mode 100644 app/views/devise/passwords/.DS_Store create mode 100644 app/views/devise/passwords/edit.html.erb create mode 100644 app/views/devise/passwords/new.html.erb create mode 100644 app/views/devise/registrations/.DS_Store create mode 100644 app/views/devise/registrations/edit.html.erb create mode 100644 app/views/devise/registrations/new.html.erb create mode 100644 app/views/devise/sessions/.DS_Store create mode 100644 app/views/devise/sessions/_new.html.erb create mode 100644 app/views/devise/sessions/new.html.erb create mode 100644 app/views/devise/shared/.DS_Store create mode 100644 app/views/devise/shared/_links.html.erb create mode 100644 app/views/devise/unlocks/new.html.erb create mode 100644 app/views/layouts/.DS_Store create mode 100644 app/views/layouts/_header.html.erb create mode 100644 app/views/layouts/application.html.erb create mode 100644 app/views/layouts/mailer.html.erb create mode 100644 app/views/layouts/mailer.text.erb create mode 100644 app/views/users/_user.html.erb create mode 100644 app/views/users/index.html.erb create mode 100644 app/views/users/show.html.erb create mode 100755 bin/bundle create mode 100755 bin/rails create mode 100755 bin/rake create mode 100755 bin/setup create mode 100755 bin/spring create mode 100755 bin/update create mode 100755 bin/yarn create mode 100644 config.ru create mode 100644 config/.DS_Store create mode 100644 config/application.rb create mode 100644 config/boot.rb create mode 100644 config/cable.yml create mode 100644 config/credentials.yml.enc create mode 100644 config/database.yml create mode 100644 config/environment.rb create mode 100644 config/environments/.DS_Store create mode 100644 config/environments/development.rb create mode 100644 config/environments/production.rb create mode 100644 config/environments/test.rb create mode 100644 config/initializers/.DS_Store create mode 100644 config/initializers/application_controller_renderer.rb create mode 100644 config/initializers/assets.rb create mode 100644 config/initializers/backtrace_silencers.rb create mode 100644 config/initializers/content_security_policy.rb create mode 100644 config/initializers/cookies_serializer.rb create mode 100644 config/initializers/devise.rb create mode 100644 config/initializers/filter_parameter_logging.rb create mode 100644 config/initializers/inflections.rb create mode 100644 config/initializers/mime_types.rb create mode 100644 config/initializers/wrap_parameters.rb create mode 100644 config/locales/devise.en.yml create mode 100644 config/locales/en.yml create mode 100644 config/puma.rb create mode 100644 config/routes.rb create mode 100644 config/spring.rb create mode 100644 config/storage.yml create mode 100644 db/.DS_Store create mode 100644 db/migrate/.DS_Store create mode 100644 db/migrate/20180815235126_devise_create_users.rb create mode 100644 db/schema.rb create mode 100644 db/seeds.rb create mode 100644 lib/assets/.keep create mode 100644 lib/tasks/.keep create mode 100644 log/.keep create mode 100644 package.json create mode 100644 public/404.html create mode 100644 public/422.html create mode 100644 public/500.html create mode 100644 public/apple-touch-icon-precomposed.png create mode 100644 public/apple-touch-icon.png create mode 100644 public/favicon.ico create mode 100644 public/robots.txt create mode 100644 storage/.keep create mode 100644 test/.DS_Store create mode 100644 test/application_system_test_case.rb create mode 100644 test/controllers/.DS_Store create mode 100644 test/controllers/.keep create mode 100644 test/controllers/users_controller_test.rb create mode 100644 test/fixtures/.DS_Store create mode 100644 test/fixtures/.keep create mode 100644 test/fixtures/files/.keep create mode 100644 test/fixtures/users.yml create mode 100644 test/helpers/.keep create mode 100644 test/integration/.DS_Store create mode 100644 test/integration/.keep create mode 100644 test/integration/user_signup_test.rb create mode 100644 test/mailers/.keep create mode 100644 test/models/.DS_Store create mode 100644 test/models/.keep create mode 100644 test/models/user_test.rb create mode 100644 test/system/.keep create mode 100644 test/test_helper.rb create mode 100644 tmp/.keep create mode 100644 vendor/.keep diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..1e427332ad780318afb4e45dc68cd0b9ba610f8f GIT binary patch literal 8196 zcmeHMTTc@~6h6}yx-A%M)QIt=FD94}(uRQH!K75s@IXSSff!NfwkxcZ-KG~R)|x*1 z3)DyN|HDXP;=B4&e8TU{4$bbiyqRdq44FBzGvArZH)qf6DMTdl&2pA#f`|-cmZ>om z0}}Uh?n@EXaurfQpWKpJaZNm>`mnk|GoTsJ3}^;41Db*Vg8|&xoQzZMeXm!SngPwg znPhJgG~~fM%ed0gm0HRHQ0Zmn(tz{SJC2krT(q zQca=ER=ujC{BLHpV%Hm)%nuQX#zscthLJRq=aLT#yKbw{C^nk)e6jX`pH_>FT~pQX zxo)LbFPiJN)!Is3y6rlRqU~5Usce@mKsGmQr|h=!Zqq5(m7q8_8NGRVy=e_4%`35z$y@Nu{ zskqJ#S{NNAlWcNA)O<(Jinh!S1pafuQv+4Cf;0LNhyeBW`yBeuR&`VeGj7#+#i9F06qcy5-rdo ztw2uW1j@k~BqRPA;#hM7tFC#w2%)j(!1ys>E!GI)c#rZMC#ej+hw~Zz?-Pgo>%<`^ zl4Jarx-iHoD`)z*9Q39dZ^JG(cDGWOS8LV*eEVwAvDWRnZQ2#PambFl=ep&lpTB&CVIcJ!_(kuzS014j1#$a>Zn1!Qj?w|>bzsgo zkRZkKsQsqg8-7SDQEy)p9RDw!{`>!s?p|+8GoTq@21IPJu$bq{DSU9Ookre9=ES(J zC#4Ds8ID8Ba2&Gt4@1<`fU-_b$*w2Sg7go52ngJ_`u^AVKg^JSHsVjcGjsp{0V;)% A+yDRo literal 0 HcmV?d00001 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..220f240 --- /dev/null +++ b/.gitignore @@ -0,0 +1,30 @@ +# See https://help.github.com/articles/ignoring-files for more about ignoring files. +# +# If you find yourself ignoring temporary files generated by your text editor +# or operating system, you probably want to add a global ignore instead: +# git config --global core.excludesfile '~/.gitignore_global' + +# Ignore bundler config. +/.bundle + +# Ignore all logfiles and tempfiles. +/log/* +/tmp/* +!/log/.keep +!/tmp/.keep + +# Ignore uploaded files in development +/storage/* +!/storage/.keep + +/node_modules +/yarn-error.log + +/public/assets +.byebug_history + +# Ignore master key for decrypting credentials and more. +/config/master.key + +# Ignore Spring files. +/spring/*.pid diff --git a/.ruby-version b/.ruby-version new file mode 100644 index 0000000..fb47d6c --- /dev/null +++ b/.ruby-version @@ -0,0 +1 @@ +ruby-2.3.3 \ No newline at end of file diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000..3eceda7 --- /dev/null +++ b/Gemfile @@ -0,0 +1,69 @@ +source 'https://rubygems.org' +git_source(:github) { |repo| "https://github.com/#{repo}.git" } + +ruby '2.3.3' + +# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' +gem 'rails', '~> 5.2.1' +# Use postgresql as the database for Active Record +gem 'pg', '>= 0.18', '< 2.0' +# Use Puma as the app server +gem 'puma', '~> 3.11' +# Use SCSS for stylesheets +gem 'sass-rails', '~> 5.0' +# Use Uglifier as compressor for JavaScript assets +gem 'uglifier', '>= 1.3.0' +# See https://github.com/rails/execjs#readme for more supported runtimes +# gem 'mini_racer', platforms: :ruby + +# Use CoffeeScript for .coffee assets and views +gem 'coffee-rails', '~> 4.2' +# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks +gem 'turbolinks', '~> 5' +# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder +gem 'jbuilder', '~> 2.5' +# Use Redis adapter to run Action Cable in production +# gem 'redis', '~> 4.0' +# Use ActiveModel has_secure_password +# gem 'bcrypt', '~> 3.1.7' + +# Use ActiveStorage variant +# gem 'mini_magick', '~> 4.8' + +# Use Capistrano for deployment +# gem 'capistrano-rails', group: :development + +# Reduces boot times through caching; required in config/boot.rb +gem 'bootsnap', '>= 1.1.0', require: false + +gem 'devise', '4.4.3' + +group :development, :test do + # Call 'byebug' anywhere in the code to stop execution and get a debugger console + gem 'byebug', platforms: [:mri, :mingw, :x64_mingw] + gem 'guard', '~> 2.14' + gem 'guard-minitest', '2.4.4' +end + +group :development do + # Access an interactive console on exception pages or by calling 'console' anywhere in the code. + gem 'web-console', '>= 3.3.0' + gem 'listen', '>= 3.0.5', '< 3.2' + # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring + gem 'spring' + gem 'spring-watcher-listen', '~> 2.0.0' + gem 'guard-livereload', '~> 2.5' + gem "rack-livereload" +end + +group :test do + # Adds support for Capybara system testing and selenium driver + gem 'capybara', '>= 2.15' + gem 'selenium-webdriver' + # Easy installation and use of chromedriver to run system tests with Chrome + gem 'chromedriver-helper' + gem 'rails-controller-testing' +end + +# Windows does not include zoneinfo files, so bundle the tzinfo-data gem +gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby] diff --git a/Gemfile.lock b/Gemfile.lock new file mode 100644 index 0000000..1115e0e --- /dev/null +++ b/Gemfile.lock @@ -0,0 +1,277 @@ +GEM + remote: https://rubygems.org/ + specs: + actioncable (5.2.1) + actionpack (= 5.2.1) + nio4r (~> 2.0) + websocket-driver (>= 0.6.1) + actionmailer (5.2.1) + actionpack (= 5.2.1) + actionview (= 5.2.1) + activejob (= 5.2.1) + mail (~> 2.5, >= 2.5.4) + rails-dom-testing (~> 2.0) + actionpack (5.2.1) + actionview (= 5.2.1) + activesupport (= 5.2.1) + rack (~> 2.0) + rack-test (>= 0.6.3) + rails-dom-testing (~> 2.0) + rails-html-sanitizer (~> 1.0, >= 1.0.2) + actionview (5.2.1) + activesupport (= 5.2.1) + builder (~> 3.1) + erubi (~> 1.4) + rails-dom-testing (~> 2.0) + rails-html-sanitizer (~> 1.0, >= 1.0.3) + activejob (5.2.1) + activesupport (= 5.2.1) + globalid (>= 0.3.6) + activemodel (5.2.1) + activesupport (= 5.2.1) + activerecord (5.2.1) + activemodel (= 5.2.1) + activesupport (= 5.2.1) + arel (>= 9.0) + activestorage (5.2.1) + actionpack (= 5.2.1) + activerecord (= 5.2.1) + marcel (~> 0.3.1) + activesupport (5.2.1) + concurrent-ruby (~> 1.0, >= 1.0.2) + i18n (>= 0.7, < 2) + minitest (~> 5.1) + tzinfo (~> 1.1) + addressable (2.5.2) + public_suffix (>= 2.0.2, < 4.0) + archive-zip (0.11.0) + io-like (~> 0.3.0) + arel (9.0.0) + bcrypt (3.1.12) + bindex (0.5.0) + bootsnap (1.3.1) + msgpack (~> 1.0) + builder (3.2.3) + byebug (10.0.2) + capybara (3.6.0) + addressable + mini_mime (>= 0.1.3) + nokogiri (~> 1.8) + rack (>= 1.6.0) + rack-test (>= 0.6.3) + xpath (~> 3.1) + childprocess (0.9.0) + ffi (~> 1.0, >= 1.0.11) + chromedriver-helper (1.2.0) + archive-zip (~> 0.10) + nokogiri (~> 1.8) + coderay (1.1.2) + coffee-rails (4.2.2) + coffee-script (>= 2.2.0) + railties (>= 4.0.0) + coffee-script (2.4.1) + coffee-script-source + execjs + coffee-script-source (1.12.2) + concurrent-ruby (1.0.5) + crass (1.0.4) + devise (4.4.3) + bcrypt (~> 3.0) + orm_adapter (~> 0.1) + railties (>= 4.1.0, < 6.0) + responders + warden (~> 1.2.3) + em-websocket (0.5.1) + eventmachine (>= 0.12.9) + http_parser.rb (~> 0.6.0) + erubi (1.7.1) + eventmachine (1.2.7) + execjs (2.7.0) + ffi (1.9.25) + formatador (0.2.5) + globalid (0.4.1) + activesupport (>= 4.2.0) + guard (2.14.2) + formatador (>= 0.2.4) + listen (>= 2.7, < 4.0) + lumberjack (>= 1.0.12, < 2.0) + nenv (~> 0.1) + notiffany (~> 0.0) + pry (>= 0.9.12) + shellany (~> 0.0) + thor (>= 0.18.1) + guard-compat (1.2.1) + guard-livereload (2.5.2) + em-websocket (~> 0.5) + guard (~> 2.8) + guard-compat (~> 1.0) + multi_json (~> 1.8) + guard-minitest (2.4.4) + guard-compat (~> 1.2) + minitest (>= 3.0) + http_parser.rb (0.6.0) + i18n (1.1.0) + concurrent-ruby (~> 1.0) + io-like (0.3.0) + jbuilder (2.7.0) + activesupport (>= 4.2.0) + multi_json (>= 1.2) + listen (3.1.5) + rb-fsevent (~> 0.9, >= 0.9.4) + rb-inotify (~> 0.9, >= 0.9.7) + ruby_dep (~> 1.2) + loofah (2.2.2) + crass (~> 1.0.2) + nokogiri (>= 1.5.9) + lumberjack (1.0.13) + mail (2.7.0) + mini_mime (>= 0.1.1) + marcel (0.3.2) + mimemagic (~> 0.3.2) + method_source (0.9.0) + mimemagic (0.3.2) + mini_mime (1.0.1) + mini_portile2 (2.3.0) + minitest (5.11.3) + msgpack (1.2.4) + multi_json (1.13.1) + nenv (0.3.0) + nio4r (2.3.1) + nokogiri (1.8.4) + mini_portile2 (~> 2.3.0) + notiffany (0.1.1) + nenv (~> 0.1) + shellany (~> 0.0) + orm_adapter (0.5.0) + pg (1.1.2) + pry (0.11.3) + coderay (~> 1.1.0) + method_source (~> 0.9.0) + public_suffix (3.0.3) + puma (3.12.0) + rack (2.0.5) + rack-livereload (0.3.17) + rack + rack-test (1.1.0) + rack (>= 1.0, < 3) + rails (5.2.1) + actioncable (= 5.2.1) + actionmailer (= 5.2.1) + actionpack (= 5.2.1) + actionview (= 5.2.1) + activejob (= 5.2.1) + activemodel (= 5.2.1) + activerecord (= 5.2.1) + activestorage (= 5.2.1) + activesupport (= 5.2.1) + bundler (>= 1.3.0) + railties (= 5.2.1) + sprockets-rails (>= 2.0.0) + rails-controller-testing (1.0.2) + actionpack (~> 5.x, >= 5.0.1) + actionview (~> 5.x, >= 5.0.1) + activesupport (~> 5.x) + rails-dom-testing (2.0.3) + activesupport (>= 4.2.0) + nokogiri (>= 1.6) + rails-html-sanitizer (1.0.4) + loofah (~> 2.2, >= 2.2.2) + railties (5.2.1) + actionpack (= 5.2.1) + activesupport (= 5.2.1) + method_source + rake (>= 0.8.7) + thor (>= 0.19.0, < 2.0) + rake (12.3.1) + rb-fsevent (0.10.3) + rb-inotify (0.9.10) + ffi (>= 0.5.0, < 2) + responders (2.4.0) + actionpack (>= 4.2.0, < 5.3) + railties (>= 4.2.0, < 5.3) + ruby_dep (1.5.0) + rubyzip (1.2.1) + sass (3.5.7) + sass-listen (~> 4.0.0) + sass-listen (4.0.0) + rb-fsevent (~> 0.9, >= 0.9.4) + rb-inotify (~> 0.9, >= 0.9.7) + sass-rails (5.0.7) + railties (>= 4.0.0, < 6) + sass (~> 3.1) + sprockets (>= 2.8, < 4.0) + sprockets-rails (>= 2.0, < 4.0) + tilt (>= 1.1, < 3) + selenium-webdriver (3.14.0) + childprocess (~> 0.5) + rubyzip (~> 1.2) + shellany (0.0.1) + spring (2.0.2) + activesupport (>= 4.2) + spring-watcher-listen (2.0.1) + listen (>= 2.7, < 4.0) + spring (>= 1.2, < 3.0) + sprockets (3.7.2) + concurrent-ruby (~> 1.0) + rack (> 1, < 3) + sprockets-rails (3.2.1) + actionpack (>= 4.0) + activesupport (>= 4.0) + sprockets (>= 3.0.0) + thor (0.20.0) + thread_safe (0.3.6) + tilt (2.0.8) + turbolinks (5.2.0) + turbolinks-source (~> 5.2) + turbolinks-source (5.2.0) + tzinfo (1.2.5) + thread_safe (~> 0.1) + uglifier (4.1.18) + execjs (>= 0.3.0, < 3) + warden (1.2.7) + rack (>= 1.0) + web-console (3.6.2) + actionview (>= 5.0) + activemodel (>= 5.0) + bindex (>= 0.4.0) + railties (>= 5.0) + websocket-driver (0.7.0) + websocket-extensions (>= 0.1.0) + websocket-extensions (0.1.3) + xpath (3.1.0) + nokogiri (~> 1.8) + +PLATFORMS + ruby + +DEPENDENCIES + bootsnap (>= 1.1.0) + byebug + capybara (>= 2.15) + chromedriver-helper + coffee-rails (~> 4.2) + devise (= 4.4.3) + guard (~> 2.14) + guard-livereload (~> 2.5) + guard-minitest (= 2.4.4) + jbuilder (~> 2.5) + listen (>= 3.0.5, < 3.2) + pg (>= 0.18, < 2.0) + puma (~> 3.11) + rack-livereload + rails (~> 5.2.1) + rails-controller-testing + sass-rails (~> 5.0) + selenium-webdriver + spring + spring-watcher-listen (~> 2.0.0) + turbolinks (~> 5) + tzinfo-data + uglifier (>= 1.3.0) + web-console (>= 3.3.0) + +RUBY VERSION + ruby 2.3.3p222 + +BUNDLED WITH + 1.16.3 diff --git a/Guardfile b/Guardfile new file mode 100644 index 0000000..cb6202d --- /dev/null +++ b/Guardfile @@ -0,0 +1,81 @@ +# A sample Guardfile +# More info at https://github.com/guard/guard#readme + +## Uncomment and set this to only include directories you want to watch +# directories %w(app lib config test spec features) \ +# .select{|d| Dir.exists?(d) ? d : UI.warning("Directory #{d} does not exist")} + +## Note: if you are using the `directories` clause above and you are not +## watching the project directory ('.'), then you will want to move +## the Guardfile to a watched dir and symlink it back, e.g. +# +# $ mkdir config +# $ mv Guardfile config/ +# $ ln -s config/Guardfile . +# +# and, you'll have to watch "config/Guardfile" instead of "Guardfile" + +# Defines the matching rules for Guard. +guard 'livereload' do + watch(%r{app/views/.+\.(erb|haml|slim)}) + watch(%r{app/helpers/.+\.rb}) + watch(%r{public/.+\.(scss|css|js|html)}) + watch(%r{config/locales/.+\.yml}) + # Rails Assets Pipeline + watch(%r{(app|vendor)(/assets/\w+/(.+\.(scss|css|js|html))).*}) { |m| "/assets/#{m[3]}" } +end + +guard :minitest, spring: "bin/rails test", all_on_start: false do + watch(%r{^test/(.*)/?(.*)_test\.rb$}) + watch('test/test_helper.rb') { 'test' } + watch('config/routes.rb') { integration_tests } + watch(%r{^app/models/(.*?)\.rb$}) do |matches| + "test/models/#{matches[1]}_test.rb" + end + watch(%r{^app/controllers/(.*?)_controller\.rb$}) do |matches| + resource_tests(matches[1]) + end + watch(%r{^app/views/([^/]*?)/.*\.html\.erb$}) do |matches| + ["test/controllers/#{matches[1]}_controller_test.rb"] + + integration_tests(matches[1]) + end + watch(%r{^app/helpers/(.*?)_helper\.rb$}) do |matches| + integration_tests(matches[1]) + end + watch('app/views/layouts/application.html.erb') do + 'test/integration/site_layout_test.rb' + end + watch('app/helpers/sessions_helper.rb') do + integration_tests << 'test/helpers/sessions_helper_test.rb' + end + watch('app/controllers/sessions_controller.rb') do + ['test/controllers/sessions_controller_test.rb', + 'test/integration/users_login_test.rb'] + end + watch('app/controllers/account_activations_controller.rb') do + 'test/integration/users_signup_test.rb' + end + watch(%r{app/views/users/*}) do + resource_tests('users') + + ['test/integration/microposts_interface_test.rb'] + end +end + +# Returns the integration tests corresponding to the given resource. +def integration_tests(resource = :all) + if resource == :all + Dir["test/integration/*"] + else + Dir["test/integration/#{resource}_*.rb"] + end +end + +# Returns the controller tests corresponding to the given resource. +def controller_test(resource) + "test/controllers/#{resource}_controller_test.rb" +end + +# Returns all tests for the given resource. +def resource_tests(resource) + integration_tests(resource) << controller_test(resource) +end diff --git a/README.md b/README.md new file mode 100644 index 0000000..f54a01b --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +This is the final project of The Odin Project’s Ruby on Rails Curriculum. Find it at https://www.theodinproject.com/courses/ruby-on-rails/lessons/final-project diff --git a/Rakefile b/Rakefile new file mode 100644 index 0000000..e85f913 --- /dev/null +++ b/Rakefile @@ -0,0 +1,6 @@ +# Add your own tasks in files placed in lib/tasks ending in .rake, +# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. + +require_relative 'config/application' + +Rails.application.load_tasks diff --git a/app/.DS_Store b/app/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..41fc754fe2fdf766259ce12abf63ceaf4f5d4916 GIT binary patch literal 8196 zcmeI0O=}ZD7{{M!({_?ljHtBWWiLX791^v~9E2FF(1TEnw20Mqw^_`}b~j|V4K+q` z_7hZ(zJCr;LGZ4A6L0lDFDct?a+4@_W|{fV&OFb~?(fO&=2;?Q)t!2YXpV?Ds?hv2 zngK=3i+Ze#>5&;IgFjJB(Xt7ffOtMws6s1RdrIY_1C2}ppcxFyf0@cFXzeMLt~jR39+-AzI>lhh9rKnj zhgP)qlqz>(%AJ^AnduCL$<^U!NpoTqrKU9m41wbWMD9LGHbvOnRQ@h*rCX@;sQlmn zZOYbZM@^mUe|4I^7sbWmcQ!VjnV6j7JjZi0xd*jI*sjHPyc1RJ)_t+JV#f_f_wRv+gV^>0waMJvYd&tF`)e*0dt`~21GH*ep)|M2mXfCeJ{_?%JuhwW$drVs(azB!QP z4_G84kfFyQ@1&WJJxtk6(Kh1h4UUk!5%v>torHBr^`XCkr0oRl;bNH?6S4lUZmz^79=WyD3*5Z_@oO-}5Euc0aka*r$p3E+|NcLMGcijT0*1ifBET|B zwWTUn@BimYpNPn{E!0g^QG{JjsdPaj({ZRw$DukMm$nv6g-=CmPbo%F%!dGp!8C@z HND2G~vFt__ literal 0 HcmV?d00001 diff --git a/app/assets/.DS_Store b/app/assets/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..d44a2ab245bb754ffe29f86f834e00ed3cb43137 GIT binary patch literal 8196 zcmeI1--{Aa6vxk1+eRfaDpu%aUV;sL(6!z4Au!v5eF!9DmuSPCS!Z=(c1E00F*AJb zKd8rk{~b|5(0lct^k(PWdo|Y|P_V=<-7}o?y>sWBQ9tTj&j3Dml9KoL*`jspQ)v&pmt>%KUuq9ULO z{Femi`k-U6UTaGD#Au@B%iy3~TyflywG=M>!olch|y7)+Goah=jp z3sMI{ML9504op5WlN}1v*nW^s|6rkTEgFl{mN*xCSgw1Wa$p24zi2cc@IAX~nQ~k* zg8FED&-0w|*f6(jt5Zo_xaqlpVY^myqI755cB@{e=(XIczf%_H+qSDgy^^?CYFce9 zEg7!0W&5^iJ9g03qO?^K%e`JUcQvKwSNkcwm(QnD`g(f3-%otjv`bgkZrr)w=s$b; z>h+tq@7{m-$X_)udD(&UVt*VzaV9n#fB`kIz@NDPLHxd=uMD~Inm9bd%r?4@)SF1W z0l{zGP4 V1*rp}ID@8c1aJ&0C<6bKz%QKwA5Ukb<4lcRSa6%)&KNyZvF!l%Ze1LL#!D+sc-{qfa^#fs9O#~CEhVGi_ z?b_L`V0#;YtzK_WfhB-B-4Smdrsmh(Cw5R7Bhq<~d)#4<7o6a6QvH3xxeGku8qatb z@%I=w9(T=(Cc6<~?S=W5c>%DMD3_9~cC+cUwb&*MdzgFNA<6#@) literal 0 HcmV?d00001 diff --git a/app/assets/config/manifest.js b/app/assets/config/manifest.js new file mode 100644 index 0000000..b16e53d --- /dev/null +++ b/app/assets/config/manifest.js @@ -0,0 +1,3 @@ +//= link_tree ../images +//= link_directory ../javascripts .js +//= link_directory ../stylesheets .css diff --git a/app/assets/images/.keep b/app/assets/images/.keep new file mode 100644 index 0000000..e69de29 diff --git a/app/assets/javascripts/.DS_Store b/app/assets/javascripts/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..928038b2785dac9aff1d814b43ffe127a9a1b094 GIT binary patch literal 6148 zcmeHKJx{|h5Pb(7DuGZp7(FsoVrGe|GBEQ8ASH-aQG+Pmv+!g1mGI7YfD$|-gzhZ+ zo$Y(J^Q8C#fGqa+7r+d_lvz>KDVR1FyAC{fLX$Y3fZC5i+MY?1@f6qowg;7RLZc~hZE5tvNv1Mw=8jUZfqxfU&v18;j z%Q@%j@W9ld8LmrSM?6-;LV-{q6bJ=EfuaIDv(=_YhEawBp+G3`rGV}aiCM97><#nQ z!6H8ah7xc{3t(Le|(;vwTbzbSxw`5 ob!hYlmjG6DA34jN)}Pd8T;L}Wt>BP7QWI>_`1%5$+55LSrk^lez literal 0 HcmV?d00001 diff --git a/app/assets/javascripts/application.js b/app/assets/javascripts/application.js new file mode 100644 index 0000000..82e6f0f --- /dev/null +++ b/app/assets/javascripts/application.js @@ -0,0 +1,16 @@ +// This is a manifest file that'll be compiled into application.js, which will include all the files +// listed below. +// +// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, or any plugin's +// vendor/assets/javascripts directory can be referenced here using a relative path. +// +// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the +// compiled file. JavaScript code in this file should be added after the last require_* statement. +// +// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details +// about supported directives. +// +//= require rails-ujs +//= require activestorage +//= require turbolinks +//= require_tree . diff --git a/app/assets/javascripts/cable.js b/app/assets/javascripts/cable.js new file mode 100644 index 0000000..739aa5f --- /dev/null +++ b/app/assets/javascripts/cable.js @@ -0,0 +1,13 @@ +// Action Cable provides the framework to deal with WebSockets in Rails. +// You can generate new channels where WebSocket features live using the `rails generate channel` command. +// +//= require action_cable +//= require_self +//= require_tree ./channels + +(function() { + this.App || (this.App = {}); + + App.cable = ActionCable.createConsumer(); + +}).call(this); diff --git a/app/assets/javascripts/channels/.keep b/app/assets/javascripts/channels/.keep new file mode 100644 index 0000000..e69de29 diff --git a/app/assets/javascripts/users.coffee b/app/assets/javascripts/users.coffee new file mode 100644 index 0000000..24f83d1 --- /dev/null +++ b/app/assets/javascripts/users.coffee @@ -0,0 +1,3 @@ +# Place all the behaviors and hooks related to the matching controller here. +# All this logic will automatically be available in application.js. +# You can use CoffeeScript in this file: http://coffeescript.org/ diff --git a/app/assets/stylesheets/.DS_Store b/app/assets/stylesheets/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..125a488c103b1c71eeba9ea65f5f0d13e74750e9 GIT binary patch literal 6148 zcmeHKyG{c^3>-s>2#Tbn+>$C1HO(pt1vNha2^5h|TtrBJUA~2{gz$%NMaozK0#u@z(=j9v6h#69WR3H^d1yX^3sQ`Pn z+W6ElV=9meqyirb==Y(}6>DJUXrB%SJ-+MuNKuVryGsyD%xhrh$Q7D6mFQH7D~33o z`4V+Cuyb@e#CGO$VrPjPirDVV7b}NU$Bd~!D$rNp*r!wN|5x-M?*DyK&QgI?;7=(a zqs7f)&R2@wI(RwlwS|65e>c`zIYaLdz=^ivvoCc;$E>S?oukp2H##v70;)?|D)1W$ FyaAPhD;@v< literal 0 HcmV?d00001 diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.css new file mode 100644 index 0000000..7fd2bf4 --- /dev/null +++ b/app/assets/stylesheets/application.css @@ -0,0 +1,24 @@ +/* + * This is a manifest file that'll be compiled into application.css, which will include all the files + * listed below. + * + * Any CSS and SCSS file within this directory, lib/assets/stylesheets, or any plugin's + * vendor/assets/stylesheets directory can be referenced here using a relative path. + * + * You're free to add application-wide styles to this file and they'll appear at the bottom of the + * compiled file so the styles you add here take precedence over styles defined in any other CSS/SCSS + * files in this directory. Styles in this file should be added after the last require_* statement. + * It is generally better to create a new file per style scope. + * + *= require_tree . + *= require_self + */ + + * { + font-family: sans-serif; + margin: 0 !important; + } + + body { + background-color: #eeeff4; + } diff --git a/app/assets/stylesheets/users.scss b/app/assets/stylesheets/users.scss new file mode 100644 index 0000000..31a2eac --- /dev/null +++ b/app/assets/stylesheets/users.scss @@ -0,0 +1,3 @@ +// Place all the styles related to the Users controller here. +// They will automatically be included in application.css. +// You can use Sass (SCSS) here: http://sass-lang.com/ diff --git a/app/channels/application_cable/channel.rb b/app/channels/application_cable/channel.rb new file mode 100644 index 0000000..d672697 --- /dev/null +++ b/app/channels/application_cable/channel.rb @@ -0,0 +1,4 @@ +module ApplicationCable + class Channel < ActionCable::Channel::Base + end +end diff --git a/app/channels/application_cable/connection.rb b/app/channels/application_cable/connection.rb new file mode 100644 index 0000000..0ff5442 --- /dev/null +++ b/app/channels/application_cable/connection.rb @@ -0,0 +1,4 @@ +module ApplicationCable + class Connection < ActionCable::Connection::Base + end +end diff --git a/app/controllers/.DS_Store b/app/controllers/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..98ae4096c4c243d2e92fe6d3f81313b0aeb6963f GIT binary patch literal 6148 zcmeHKU5nE|6ur|{H{E@StfJye9#<$*zZUxz>nivl6f3)kD>Z2Y9SE7yq+6sE^6by> z`*(=?#_*T!InXcBl;FE~V9qybvlY1uQOp=))BGH}(15=a)(G_@nKUMuW zRWaE7>fD3xz-x;IYJOb|v#%K$<-g>AK@R6vPs)#{`N)p{Egq#ZFPhD-qEfA$I=$i5 zH@CR>XEvX9hicj_qGFP_qwy2nl7l3+aVIK<%lMH}>2Vyz`!bpK{IhpdRzxyO#y?RH z4`en_)3%yqgZ!{-#ygOMV%YP~b;ijNsGTTF_GK<(nabk1SLf36&(CJpZ{27Ft!wi} zFl)7%jbOLAJD>ZXJ@3-xo3|f49?f68eD(Ux+js9jd}N{U;o!^Bwrz0t(9Kaa0)mDoC11JPXUDB|3ql9G^l?asPqv4 z$lFM5h*I;|DsO zL}<{}P64ODssdHh^m+Zid-C~zmE>AZ0jI!!rGTjIb@$qMB)hh*JshvK0sI-9jq^%_ l#}ov5DMl_Y#TVe(&>wIB3@w%h(F1cE0WE{8oC1GUf$wm@iQoVL literal 0 HcmV?d00001 diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb new file mode 100644 index 0000000..76a7431 --- /dev/null +++ b/app/controllers/application_controller.rb @@ -0,0 +1,18 @@ +class ApplicationController < ActionController::Base + before_action :configure_permitted_parameters, if: :devise_controller? + protect_from_forgery with: :exception + + protected + def after_sign_up_path_for(resource) + current_user + end + + def after_sign_in_path_for(resource) + current_user #posts_path + end + + def configure_permitted_parameters + devise_parameter_sanitizer.permit(:sign_up, keys: [:first_name, :last_name, :birthday, :gender]) + devise_parameter_sanitizer.permit(:account_update, keys: [:account_update, :last_name, :birthday, :gender]) + end +end diff --git a/app/controllers/concerns/.keep b/app/controllers/concerns/.keep new file mode 100644 index 0000000..e69de29 diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb new file mode 100644 index 0000000..8c67145 --- /dev/null +++ b/app/controllers/users_controller.rb @@ -0,0 +1,16 @@ +class UsersController < ApplicationController + before_action :authenticate_user! + + def index + @users = User.all + end + + def show + if params[:id] == "sign_out" + sign_out current_user + redirect_to root_path + else + @user = User.find(params[:id]) + end + end +end diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb new file mode 100644 index 0000000..de6be79 --- /dev/null +++ b/app/helpers/application_helper.rb @@ -0,0 +1,2 @@ +module ApplicationHelper +end diff --git a/app/helpers/users_helper.rb b/app/helpers/users_helper.rb new file mode 100644 index 0000000..2310a24 --- /dev/null +++ b/app/helpers/users_helper.rb @@ -0,0 +1,2 @@ +module UsersHelper +end diff --git a/app/jobs/application_job.rb b/app/jobs/application_job.rb new file mode 100644 index 0000000..a009ace --- /dev/null +++ b/app/jobs/application_job.rb @@ -0,0 +1,2 @@ +class ApplicationJob < ActiveJob::Base +end diff --git a/app/mailers/application_mailer.rb b/app/mailers/application_mailer.rb new file mode 100644 index 0000000..286b223 --- /dev/null +++ b/app/mailers/application_mailer.rb @@ -0,0 +1,4 @@ +class ApplicationMailer < ActionMailer::Base + default from: 'from@example.com' + layout 'mailer' +end diff --git a/app/models/application_record.rb b/app/models/application_record.rb new file mode 100644 index 0000000..10a4cba --- /dev/null +++ b/app/models/application_record.rb @@ -0,0 +1,3 @@ +class ApplicationRecord < ActiveRecord::Base + self.abstract_class = true +end diff --git a/app/models/concerns/.keep b/app/models/concerns/.keep new file mode 100644 index 0000000..e69de29 diff --git a/app/models/user.rb b/app/models/user.rb new file mode 100644 index 0000000..0de5564 --- /dev/null +++ b/app/models/user.rb @@ -0,0 +1,9 @@ +class User < ApplicationRecord + # Include default devise modules. Others available are: + # :confirmable, :lockable, :timeoutable and :omniauthable + devise :database_authenticatable, :registerable, + :recoverable, :rememberable, :trackable, :validatable + validates :first_name, presence: true + validates :last_name, presence: true + validates :gender, presence: true +end diff --git a/app/views/.DS_Store b/app/views/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..2f2b0e37629d7e0e4a5590a3760aad488775187a GIT binary patch literal 6148 zcmeH~&ubGw6vyARX*)>~SFE()WiLX791?AUITT{7LJvYP(jr#UU3X~~*4>cZB*YlW z+5bR~{{A~e1;M-cpLmP!%}heFsTZ+QWnOsmonLRle3&0Q0Kh73Cl6o%07oZHWiUC$ zsGWSy7E}#2GBHL3?yes`wEfVY>#Zv^0Zrhv5um-h3=X)^0S{*PFC7ZE&^OW3qY^UxWIoS6CC+t?jcHl%}oSJOlJk8T}W24`{S}bPGd|_*l zHT$JfE^8KZ#laxW*DvL_cMl)+9`~ONo<0}T0EP#au(L|X@&Yq6KsvQn;D^Bx)>F(1 z_+UW~LTEz_(bREAxW1wjF0ODTdQSoSF$VU13@n{lrJr%`IB06Je+uA%8gJio;zr%L zP;I##WM8!cch8GF+w;A+M_>uG1YU5-Dy~C`BI4%TVWQ-Z!ET{DJGWM zgxLvY)E3~YCp5kuRuj+!{#^oeKA7mFWu-%@;^@FcJONNsSS<|mbPrODskE$gC>2}K zm<&agp-eq7m<-2yQ}rt=9ZHqqz|`Y|sefklA%n)mzoVL1Kx1VgI?)6)fdqj?SvKhY zzxnI;eBtsUidubsdWgUBw&d!m!Px X3~E{FP%74-=??*cK_{BPUnTGp^U(yP literal 0 HcmV?d00001 diff --git a/app/views/devise/.DS_Store b/app/views/devise/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..6fe1e973f52a6d524c81cb451a49902db9dfac56 GIT binary patch literal 8196 zcmeHMU2D@|6h7}(x3t@^qOyTExe*k4(dky)g;47hb|DNa8{%|JmbeD9q$KIetd(B- z3#ONT{|-?>@Lv5V-p%LzXz9|<8)Xdkp75UMBsnJ^PfkvH-Vzb3G@MzY86q+;IOZpy zh6vx!$AFBeEt5cocp{G?+9rzW53DWfn|jq zi87p+3@4_}%v6WM#Mu#N3U^{xT;wBf~H ztlJou_JzPA8WY{VM?Sd}rF_4qe6v)?%s`B#iL*uIq>s+-@(2uLe;=A?NQB*t>*{)b z+jZZIlVb4~8yU@<8XGsVxe31H&*UCfYhkmRSV<$USkVKq<~gpd>}4ydb?tj$==W^P zUh&-Kdj8zaFi0#faHGD^wN)>0!e%9G1WvqGmB(B4oTRp%KffHgI|yC20(ZrWJ=^oW zWY@^@Wj#OLYF)iHS1=c@vq{HkyH8us+RtC&rXanfJ1y6H`W38!8{Mf!fgc82JP>0Hq}7m$JT;wEG2n$`4m%tl=}Edc5-+EFeWe$xS~LUy!oa8up5guft;6U4|K$`qRx_X( zIOYtn%wl!1f{X0_g4Gb>auOm@}K#6u7DB5vg?+-)RCR}+;Sz$*awm^=2 TBH-BmsMp_rkq}xP2?KushCI`E literal 0 HcmV?d00001 diff --git a/app/views/devise/confirmations/new.html.erb b/app/views/devise/confirmations/new.html.erb new file mode 100644 index 0000000..2dea366 --- /dev/null +++ b/app/views/devise/confirmations/new.html.erb @@ -0,0 +1,16 @@ +

Resend confirmation instructions

+ +<%= form_for(resource, as: resource_name, url: confirmation_path(resource_name), html: { method: :post }) do |f| %> + <%= devise_error_messages! %> + +
+ <%= f.label :email %>
+ <%= f.email_field :email, autofocus: true, autocomplete: "email", value: (resource.pending_reconfirmation? ? resource.unconfirmed_email : resource.email) %> +
+ +
+ <%= f.submit "Resend confirmation instructions" %> +
+<% end %> + +<%= render "devise/shared/links" %> diff --git a/app/views/devise/mailer/confirmation_instructions.html.erb b/app/views/devise/mailer/confirmation_instructions.html.erb new file mode 100644 index 0000000..dc55f64 --- /dev/null +++ b/app/views/devise/mailer/confirmation_instructions.html.erb @@ -0,0 +1,5 @@ +

Welcome <%= @email %>!

+ +

You can confirm your account email through the link below:

+ +

<%= link_to 'Confirm my account', confirmation_url(@resource, confirmation_token: @token) %>

diff --git a/app/views/devise/mailer/email_changed.html.erb b/app/views/devise/mailer/email_changed.html.erb new file mode 100644 index 0000000..32f4ba8 --- /dev/null +++ b/app/views/devise/mailer/email_changed.html.erb @@ -0,0 +1,7 @@ +

Hello <%= @email %>!

+ +<% if @resource.try(:unconfirmed_email?) %> +

We're contacting you to notify you that your email is being changed to <%= @resource.unconfirmed_email %>.

+<% else %> +

We're contacting you to notify you that your email has been changed to <%= @resource.email %>.

+<% end %> diff --git a/app/views/devise/mailer/password_change.html.erb b/app/views/devise/mailer/password_change.html.erb new file mode 100644 index 0000000..b41daf4 --- /dev/null +++ b/app/views/devise/mailer/password_change.html.erb @@ -0,0 +1,3 @@ +

Hello <%= @resource.email %>!

+ +

We're contacting you to notify you that your password has been changed.

diff --git a/app/views/devise/mailer/reset_password_instructions.html.erb b/app/views/devise/mailer/reset_password_instructions.html.erb new file mode 100644 index 0000000..f667dc1 --- /dev/null +++ b/app/views/devise/mailer/reset_password_instructions.html.erb @@ -0,0 +1,8 @@ +

Hello <%= @resource.email %>!

+ +

Someone has requested a link to change your password. You can do this through the link below.

+ +

<%= link_to 'Change my password', edit_password_url(@resource, reset_password_token: @token) %>

+ +

If you didn't request this, please ignore this email.

+

Your password won't change until you access the link above and create a new one.

diff --git a/app/views/devise/mailer/unlock_instructions.html.erb b/app/views/devise/mailer/unlock_instructions.html.erb new file mode 100644 index 0000000..41e148b --- /dev/null +++ b/app/views/devise/mailer/unlock_instructions.html.erb @@ -0,0 +1,7 @@ +

Hello <%= @resource.email %>!

+ +

Your account has been locked due to an excessive number of unsuccessful sign in attempts.

+ +

Click the link below to unlock your account:

+ +

<%= link_to 'Unlock my account', unlock_url(@resource, unlock_token: @token) %>

diff --git a/app/views/devise/passwords/.DS_Store b/app/views/devise/passwords/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..c59fbc266fc3ebe636adbea701409d1aa74d201d GIT binary patch literal 6148 zcmeHKu}T9$5PcI<1XM_AxusRWKR7}Zto;Ew6Hqt}h+=!4Kj%Ni_jX3faf+RV&cMvO zot<}k_llie0JeNyp8<0KGrAD33S-l}d}Ncz2(7+jfm=M`9vv2=>aP>x9%F+w?#SHd zZ}5orvfJLY-L_?wKJkKnO1IsP5jesFxi3HR-dHQ%BzWScr2?ryDv%1K0{>G1_H5bg z&@p2wkP4&%p9*MyD0E>H*gMv(gF(l4%}<3gKG(YhvBbCu>>W8nGp7=rYH`Idr!!xo zt_kcNoerxj^F6V$#SO*k>dco~4r?4UrUI$JP=Ny<&ei|V>EGP{hol^(0;#~CQoyFG ztJRXf6uouybLzE)eog-{*4A={!6ASHwc?Y#x}s;+HG#cjr88gY#5@Q{m$X#iHxzgW D30xvf literal 0 HcmV?d00001 diff --git a/app/views/devise/passwords/edit.html.erb b/app/views/devise/passwords/edit.html.erb new file mode 100644 index 0000000..6a796b0 --- /dev/null +++ b/app/views/devise/passwords/edit.html.erb @@ -0,0 +1,25 @@ +

Change your password

+ +<%= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f| %> + <%= devise_error_messages! %> + <%= f.hidden_field :reset_password_token %> + +
+ <%= f.label :password, "New password" %>
+ <% if @minimum_password_length %> + (<%= @minimum_password_length %> characters minimum)
+ <% end %> + <%= f.password_field :password, autofocus: true, autocomplete: "off" %> +
+ +
+ <%= f.label :password_confirmation, "Confirm new password" %>
+ <%= f.password_field :password_confirmation, autocomplete: "off" %> +
+ +
+ <%= f.submit "Change my password" %> +
+<% end %> + +<%= render "devise/shared/links" %> diff --git a/app/views/devise/passwords/new.html.erb b/app/views/devise/passwords/new.html.erb new file mode 100644 index 0000000..2e89181 --- /dev/null +++ b/app/views/devise/passwords/new.html.erb @@ -0,0 +1,16 @@ +

Find Your Account

+ +<%= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :post }) do |f| %> + <%= devise_error_messages! %> + +
+ <%= f.label :email %>
+ <%= f.email_field :email, autofocus: true, autocomplete: "email" %> +
+ +
+ <%= f.submit "Send me reset password instructions" %> +
+<% end %> + +<%= link_to "Cancel", new_user_session_path %> diff --git a/app/views/devise/registrations/.DS_Store b/app/views/devise/registrations/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..6e89dd3caa8fe04c6eec39e1efe6972a7a3e5557 GIT binary patch literal 6148 zcmeHKu}T9$5PfT|2&jH?Snn9_xKRT!J*o)I{~6S=z|d2g&0uW_EZVWB`M5DJ6>p}_xCfIV9_ zJvNLO3WNfoz^4M*A2MB79DBpMbuj4ouK7kN<8!@B5VMbqV{gbAS~4opsL8Jw$>_{y zuPctdq0y1*%6yNnocxB8>gvqrT8>lxyGEdit <%= resource_name.to_s.humanize %> + +<%= form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }) do |f| %> + <%= devise_error_messages! %> + +
+ <%= f.text_field :first_name, placeholder: "First name" %> + <%= f.text_field :last_name, placeholder: "Last name" %> +
+ +
+ <%= f.label :email %>
+ <%= f.email_field :email, autofocus: true, autocomplete: "email" %> +
+ + <% if devise_mapping.confirmable? && resource.pending_reconfirmation? %> +
Currently waiting confirmation for: <%= resource.unconfirmed_email %>
+ <% end %> + +
+ <%= f.label :birthday %>
+ <%= f.date_select :birthday, :order => [:month, :day, :year], start_year: Date.today.year, end_year: 1905, use_short_month: true %> +
+ +
+ <%= f.radio_button :gender, "female" %> + <%= f.label :gender, "Female" %> + <%= f.radio_button :gender, "male" %> + <%= f.label :gender, "Male" %> +
+ +
+ <%= f.label :password %> (leave blank if you don't want to change it)
+ <%= f.password_field :password, autocomplete: "off" %> + <% if @minimum_password_length %> +
+ <%= @minimum_password_length %> characters minimum + <% end %> +
+ +
+ <%= f.label :password_confirmation %>
+ <%= f.password_field :password_confirmation, autocomplete: "off" %> +
+ +
+ <%= f.label :current_password %> (we need your current password to confirm your changes)
+ <%= f.password_field :current_password, autocomplete: "off" %> +
+ +
+ <%= f.submit "Update" %> +
+<% end %> + +

Cancel my account

+ +

Unhappy? <%= button_to "Cancel my account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete %>

+ +<%= link_to "Back", :back %> diff --git a/app/views/devise/registrations/new.html.erb b/app/views/devise/registrations/new.html.erb new file mode 100644 index 0000000..2c03b0f --- /dev/null +++ b/app/views/devise/registrations/new.html.erb @@ -0,0 +1,44 @@ +

Sign up

+

It’s free and always will be.

+ +<%= form_for(resource, as: resource_name, url: registration_path(resource_name)) do |f| %> + <%= devise_error_messages! %> + +
+ <%= f.text_field :first_name, placeholder: "First name" %> + <%= f.text_field :last_name, placeholder: "Last name" %> +
+ +
+ <%= f.email_field :email, placeholder: "Email" %> +
+ +
+ <%= f.password_field :password, autocomplete: "off", placeholder: "New password" %> +
+ +
+ <%= f.password_field :password_confirmation, autocomplete: "off", placeholder: "Password confirmation" %> +
+ +
+ <%= f.label :birthday %>
+ <%= f.date_select :birthday, :order => [:month, :day, :year], start_year: Date.today.year, end_year: 1905, use_short_month: true %> +
+ +
+ <%= f.radio_button :gender, "female" %> + <%= f.label :gender, "Female" %> + <%= f.radio_button :gender, "male" %> + <%= f.label :gender, "Male" %> +
+ +

By clicking Sign Up, you agree to our <%= link_to "Terms" %>, + <%= link_to "Data Policy" %> and
<%= link_to "Cookies Policy" %>. + You may receive SMS Notifications from us and
+ can opt out any time.

+ +
+ <%= f.submit "Sign up" %> +
+<% end %> diff --git a/app/views/devise/sessions/.DS_Store b/app/views/devise/sessions/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..43da9382825221b39a50506e57b4b04c759f97df GIT binary patch literal 6148 zcmeHKyGjH>5Uf5gI8fn2!wHQJ{Db8<1!F%zSv@dV??4pO&HOq4>8zS=AImBj8E7|j z*G^B@&Ta+MGXQM)cyj{G0nF$^JS&V%^YW2RA|tf=jsp}ZLjVVA#Ydm&ik?~51on=V&U~d4^B^Ey(o%unP~a79 CCn8S( literal 0 HcmV?d00001 diff --git a/app/views/devise/sessions/_new.html.erb b/app/views/devise/sessions/_new.html.erb new file mode 100644 index 0000000..327cd18 --- /dev/null +++ b/app/views/devise/sessions/_new.html.erb @@ -0,0 +1,17 @@ +<%= form_for(resource, as: resource_name, url: session_path(resource_name)) do |f| %> +
+
  • <%= f.label :email %>
  • +
  • <%= f.email_field :email, autofocus: true, autocomplete: "email" %>
  • +
    + +
    +
  • <%= f.label :password %>
  • +
  • <%= f.password_field :password, autocomplete: "off" %>
  • +
    + +
    +
  • <%= f.submit "Log in" %>
  • +
    +<% end %> + +
  • <%= link_to "Forgot account?", new_password_path(resource_name) %>
  • diff --git a/app/views/devise/sessions/new.html.erb b/app/views/devise/sessions/new.html.erb new file mode 100644 index 0000000..328f4fa --- /dev/null +++ b/app/views/devise/sessions/new.html.erb @@ -0,0 +1,20 @@ +

    Log into Facebook

    + +<%= form_for(resource, as: resource_name, url: session_path(resource_name)) do |f| %> +
    + <%= f.email_field :email, autofocus: true, autocomplete: "email" , placeholder: "Email" %> +
    + +
    + <%= f.password_field :password, autocomplete: "off", placeholder: "Password" %> +
    + +
    + <%= f.submit "Log in" %> +
    +<% end %> + +

    or

    + +<%= link_to "Create New Account", root_path %>
    +<%= link_to "Forgot account?", new_password_path(resource_name) %> diff --git a/app/views/devise/shared/.DS_Store b/app/views/devise/shared/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..0c33e3ef935c097b7d6ff185df49fd8515e918e4 GIT binary patch literal 6148 zcmeH~F;Bxl427SeLnQ_}GTz99#6LJy1&Ns-016<12vnkF&&JO#&-Q_c0s{*JdY0^$ zIQCuh4RH^EEnja>fdzm$-4$;hrsmJxC$`rzMx}F&M{IC{du;JEss29Uy@$9$j|V)D z`g^W)hZl4g{raZs*BvYUXP(oK>9*T3%0xf}L_h>YKm>kAz-KRQevqmt0wN#+p9K8- zQ0T6;>5v+q4u&`aP-jes@jA{D)Zz(hZ91efL$hq9W~;R$hGjeRrPbA@Lu$6eVrQ3#u%Ug literal 0 HcmV?d00001 diff --git a/app/views/devise/shared/_links.html.erb b/app/views/devise/shared/_links.html.erb new file mode 100644 index 0000000..e6a3e41 --- /dev/null +++ b/app/views/devise/shared/_links.html.erb @@ -0,0 +1,25 @@ +<%- if controller_name != 'sessions' %> + <%= link_to "Log in", new_session_path(resource_name) %>
    +<% end -%> + +<%- if devise_mapping.registerable? && controller_name != 'registrations' %> + <%= link_to "Sign up", new_registration_path(resource_name) %>
    +<% end -%> + +<%- if devise_mapping.recoverable? && controller_name != 'passwords' && controller_name != 'registrations' %> + <%= link_to "Forgot your password?", new_password_path(resource_name) %>
    +<% end -%> + +<%- if devise_mapping.confirmable? && controller_name != 'confirmations' %> + <%= link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name) %>
    +<% end -%> + +<%- if devise_mapping.lockable? && resource_class.unlock_strategy_enabled?(:email) && controller_name != 'unlocks' %> + <%= link_to "Didn't receive unlock instructions?", new_unlock_path(resource_name) %>
    +<% end -%> + +<%- if devise_mapping.omniauthable? %> + <%- resource_class.omniauth_providers.each do |provider| %> + <%= link_to "Sign in with #{OmniAuth::Utils.camelize(provider)}", omniauth_authorize_path(resource_name, provider) %>
    + <% end -%> +<% end -%> diff --git a/app/views/devise/unlocks/new.html.erb b/app/views/devise/unlocks/new.html.erb new file mode 100644 index 0000000..cfe8aa8 --- /dev/null +++ b/app/views/devise/unlocks/new.html.erb @@ -0,0 +1,16 @@ +

    Resend unlock instructions

    + +<%= form_for(resource, as: resource_name, url: unlock_path(resource_name), html: { method: :post }) do |f| %> + <%= devise_error_messages! %> + +
    + <%= f.label :email %>
    + <%= f.email_field :email, autofocus: true, autocomplete: "email" %> +
    + +
    + <%= f.submit "Resend unlock instructions" %> +
    +<% end %> + +<%= render "devise/shared/links" %> diff --git a/app/views/layouts/.DS_Store b/app/views/layouts/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..65041baea6adfe37456cd08405c45e0b300a50a5 GIT binary patch literal 6148 zcmeHK!AiqG5Peg7sCY034<2*uN$?Lsse)Ji05xr)h17^t@R$$u1N@u#W_GC7G9LNBS=!%0whCQa&)jKxuo*_{z#~ceh;S5V`I-{fGH!7fO zm*JKxw!l3;uiqLKS5nurysGM1S=FVD1ultWy0k4La6;xIj|wZy*xnFpJotOipXZg_ zacgFIjDrzhQ5f<%Q3(cMkIQg>4TIAruG&LV@(N87m6)jFC59wA`*R;xI5r6r z9pc4@_?^Wo6tTNAe{RDeMZ$=oKq#=Qz(G3AbpOBTum5*RaTW@M0)I*Y8BTAe6HdwZ y*3RT~ug&RqbTu8 +