From f824ed9df6c7ff992ea40fc4c4d099ec8c39f7c4 Mon Sep 17 00:00:00 2001 From: olegphenomenon Date: Tue, 14 Sep 2021 12:12:42 +0300 Subject: [PATCH] added new forms and cards --- Gemfile | 4 +- Gemfile.lock | 7 +- app/assets/images/logo-m.png | Bin 0 -> 19214 bytes app/javascript/application.css | 3 + app/presenters/result_status_presenter.rb | 10 +- app/views/home/index.html.erb | 69 +- app/views/layouts/application.html.erb | 12 +- app/views/quiz/prepare.html.erb | 44 +- app/views/shared/_navbar.html.erb | 84 +- config/environments/production.rb | 2 +- install_nvm.sh | 425 + package-lock.json | 9678 +++++++++++++++++++++ tailwind.config.js | 13 + 13 files changed, 10276 insertions(+), 75 deletions(-) create mode 100644 app/assets/images/logo-m.png create mode 100644 app/javascript/application.css create mode 100644 install_nvm.sh create mode 100644 package-lock.json create mode 100644 tailwind.config.js diff --git a/Gemfile b/Gemfile index e29b6468..464575d7 100644 --- a/Gemfile +++ b/Gemfile @@ -61,10 +61,12 @@ group :test do gem 'capybara', '>= 3.26' gem 'selenium-webdriver' # Easy installation and use of web drivers to run system tests with browsers - gem 'simplecov' + gem 'simplecov', '0.17.1', require: false # CC last supported v0.17 gem 'webdrivers' gem 'rails-controller-testing' end # Windows does not include zoneinfo files, so bundle the tzinfo-data gem gem 'tzinfo-data', platforms: %i[mingw mswin x64_mingw jruby] + +gem "tailwindcss-rails", "~> 0.4.3" diff --git a/Gemfile.lock b/Gemfile.lock index 0734834f..70b23d1a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -281,7 +281,7 @@ GEM childprocess (>= 0.5, < 4.0) rubyzip (>= 1.2.2) semantic_range (3.0.0) - simplecov (0.17.0) + simplecov (0.17.1) docile (~> 1.1) json (>= 1.8, < 3) simplecov-html (~> 0.10.0) @@ -294,6 +294,8 @@ GEM actionpack (>= 4.0) activesupport (>= 4.0) sprockets (>= 3.0.0) + tailwindcss-rails (0.4.3) + rails (>= 6.0.0) temple (0.8.2) thor (1.1.0) tilt (2.0.10) @@ -353,8 +355,9 @@ DEPENDENCIES rspec-rails (~> 5.0.2) sass-rails (~> 6.0.0) selenium-webdriver - simplecov + simplecov (= 0.17.1) spring + tailwindcss-rails (~> 0.4.3) turbolinks (~> 5) tzinfo-data web-console (>= 4.1.0) diff --git a/app/assets/images/logo-m.png b/app/assets/images/logo-m.png new file mode 100644 index 0000000000000000000000000000000000000000..54755484ffe2e1ca06901b2f947b9845600aae16 GIT binary patch literal 19214 zcmX_oWmH^E(=9T<;1=8=xH|-Q2=4Cg?(XivVSS-q;d z>r{7F?bftV#JTu-9+cw7F-iUC@g+@B59bN-Cx*>wNC?)0PbWT=Ut_pL!F*kX{+&^IT;x>&Y#j;S^QygbT zLzX5qg>I%5MNSsWHRnKKrI7#27*k<_3cUf672=tB(DZWy!KxRj}kVLJX zbiBQkucav2H}u2$L)iLx4p&-F!-@7H=|@sQ(5B=7Ah>V<%F+-DagQm{i39CKMR`f~ zM7mea){Y9rQlOeeM#?^d7S3R*$g8H7iqiF37$RQl#I+*+e~L#)74}OrM?<`TyIRH_ zn;#4ma_ROnDbc`$t)%FVR56gXmDOl)&U)H5L6<0ygIQa3w`XmVOIs_K3facS%4%4x zLk0O$(jFE>LqkKTZpB$VJjLY7D$Dzd1B`&Ptg`ah1{d5u97LRs;g83028g*|@{H89 zG_Bv^OQ&-GR_)q%ojP@YSJV}~9V3ZCuBAw8DA%A<7RElw z7@Jc}w@bYF5(9g4s-Y=ozVXShiCf@OD@lJgJD^l& z13oz4non;Jy+U!+#uCUFewlmkRy5{pY-UY*90Ep?fDG&gJdoG92^x5XhG4RqoDxX{ zMZdjJ72r?i@GQcr9^13!@ke2`&=sTcj?9_MuROlM;hb1dTC8PG-SWWYdT)fR5dh&IR(!uyk3Iz0<^b2bASN#h35_iJjMCj->V z#o3aOib-3F_qU|P8o^a9M;o_jSlpVKff};pnGT+Trr{ zr_0qrfp8@4<93@J2b%RKDo$Ey-~o|^XDA6Pvy*%|7&;}!DwFJg4fKEf_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3p?2^7#K7j_R5z^g9 z;BObSQyqefAUtZ8Abb!^S|+Jo-BFG-;4eVi@{*xlJa|^0RJb=5ZvX$h_b#yzB&)xu zOf?8DpmQclU!NES%0&p+4*?Qf?AIs65h0K;0_R_N;gy)hkHAOtTL~A+wTzr?E$kIq znxs%*%L_`UG0;Yh2`Qg?fBXLl#hEb<|1EVT4&~zTG`Q%GI8;${IQ|lzFW!Cm=;1Hz z+P1wN`34+>f*+4G{Pi{a-iueB(g^`OBB0ojDdLF`AOsRa05%iac^A%?2mC#dScx3V z#d$qfD~SEz~7bF$@8B6>a(=7K8E}Csol5 zXBu&b<2jVu602OaG#nc+RH*6&;pyW<#ly=3%R9s4>7Ed%4~H$r4X}NY9$W39X@w_T zoQizwSl9T6mM>o(+()~HnoS500!bo3f=iNsQFcNgml2rg@l>9Z0KNnh@NHpr&~-NVu4Wvw65EgD;XY_$3*FxDLj}9^AJIh3&!pE~arf wigRonI(n!N9$R~os+2Ml0)zk|kRSs84*_Yk6QkR2{{R3007*qoM6N<$f@=tlvH$=8 literal 0 HcmV?d00001 diff --git a/app/javascript/application.css b/app/javascript/application.css new file mode 100644 index 00000000..6562f5d5 --- /dev/null +++ b/app/javascript/application.css @@ -0,0 +1,3 @@ +@import "tailwindcss/base"; +@import "tailwindcss/utilities"; +@import "tailwindcss/components"; diff --git a/app/presenters/result_status_presenter.rb b/app/presenters/result_status_presenter.rb index c8e166d8..edf97f39 100644 --- a/app/presenters/result_status_presenter.rb +++ b/app/presenters/result_status_presenter.rb @@ -12,21 +12,21 @@ def status if @quiz.theory return generate_tag(@quiz.result.result) if @quiz.result - content_tag(:span, "Waiting for chellenge") + content_tag(:span, "Waiting for chellenge", class: "text-sm px-3 py-1 bg-indigo-200 text-indigo-800 rounded-full") else @in_proccess = Practice.find_by(user: user, action_name: 'domain') @practice = PracticeResult.find_by(user: user) return generate_tag(@practice.result) unless @practice.nil? - return content_tag(:span, "In Proccess", class: "answered") unless @in_proccess.nil? - content_tag(:span, "Waiting for chellenge") + return content_tag(:span, "In Proccess", class: "text-sm px-3 py-1 bg-red-200 text-red-800 rounded-full") unless @in_proccess.nil? + content_tag(:span, "Waiting for chellenge", class: "text-sm px-3 py-1 bg-indigo-200 text-indigo-800 rounded-full") end end def generate_tag(flag) - return content_tag(:span, "True", class: "green") if flag - content_tag(:span, "Fails", class: "answered") + return content_tag(:span, "Passed", class: "text-sm px-3 py-1 bg-green-200 text-green-800 rounded-full") if flag + content_tag(:span, "Failed", class: "text-sm px-3 py-1 bg-gray-200 text-gray-800 rounded-full") end end diff --git a/app/views/home/index.html.erb b/app/views/home/index.html.erb index 8ee66285..73f7cc03 100644 --- a/app/views/home/index.html.erb +++ b/app/views/home/index.html.erb @@ -1,49 +1,44 @@ <% if user_signed_in? %> -

- <%= @result %> +
-

Your quizzes:

<% if @quizzes.any? %> - - - - - - - - - - - <% current_user.quizzes.each do |quiz| %> - - - - - - <% if quiz.theory %> - - <% else %> - - <% end %> - - <% end %> - -
IDTitleStatusTypeActions
<%= quiz.id %><%= quiz.title %> - <% quiz_presenter = ResultStatusPresenter.new(quiz: quiz, user: current_user) %> - <%= quiz_presenter.status %> - + <% current_user.quizzes.each do |quiz| %> +
+
+ +
+
<%= quiz.title %>
+ + Lorem ipsum dolor, sit amet consectetur adipisicing elit. Voluptate tempore eligendi magnam + distinctio molestias. Incidunt at consequuntur consequatur + officiis repudiandae! Culpa cum vel tenetur itaque eius provident voluptatum similique impedit? + +
+ +
+ + <% quiz_presenter = ResultStatusPresenter.new(quiz: quiz, user: current_user) %> + Status <%= quiz_presenter.status %> + +
+ <% if quiz.theory %> - Theory + <%= button_to "Let's Start", quiz_prepare_path(quiz), method: :get, class: "w-full h-16 text-lg font-extrabold text-gray-100 transition duration-300 bg-purple-600 rounded-b-lg hover:bg-purple-700 cursor-pointer" %> <% else %> - Practice + + <%= button_to "Let's Start", practice_index_path, method: :get, class: "w-full h-16 text-lg font-extrabold text-gray-100 transition duration-300 bg-purple-600 rounded-b-lg hover:bg-purple-700 cursor-pointer" %> <% end %> -
<%= link_to "Start", quiz_prepare_path(quiz), class: 'actions' %><%= link_to "Start", practice_index_path, class: 'actions' %>
- <% else %> -

No any quizzes

+ +
+ <% end %> - + <% else %> + No Any Quizzes + <% end %> + + <% else %> diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 947e5bd9..ee81653f 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -7,6 +7,8 @@ <%= csrf_meta_tags %> <%= csp_meta_tag %> + <%= stylesheet_link_tag "inter-font", "data-turbo-track": "reload" %> + <%= stylesheet_link_tag "tailwind", "data-turbo-track": "reload" %> <%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %> <%= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload' %> @@ -15,15 +17,13 @@ - + <%= render 'shared/navbar' %> -