diff --git a/Gemfile b/Gemfile index ce35e710..f63f854d 100644 --- a/Gemfile +++ b/Gemfile @@ -47,6 +47,14 @@ group :development, :test do end group :development do + # Use console on exceptions pages [https://github.com/rails/web-console] + + # Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler] + # gem "rack-mini-profiler" + + # Speed up commands on slow machines / big apps [https://github.com/rails/spring] + # gem "spring" + # Capistrano - deployment gems gem 'capistrano', '~> 3.11' gem 'capistrano-asdf' @@ -56,10 +64,6 @@ group :development do gem 'capistrano-webpacker-precompile', require: false gem 'dockerfile-rails', '>= 1.2' gem 'letter_opener' - gem 'web-console' # Use console on exceptions pages [https://github.com/rails/web-console] - - # gem "rack-mini-profiler" # Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler] - # gem "spring" #Speed up commands on slow machines / big apps [https://github.com/rails/spring] end group :test do diff --git a/Gemfile.lock b/Gemfile.lock index cd1df74a..db2a086a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -97,7 +97,6 @@ GEM aws-sigv4 (1.5.2) aws-eventstream (~> 1, >= 1.0.2) bcrypt (3.1.18) - bindex (0.8.1) bootsnap (1.11.1) msgpack (~> 1.2) builder (3.2.4) @@ -356,11 +355,6 @@ GEM unicode-display_width (2.4.2) warden (1.2.9) rack (>= 2.0.9) - web-console (4.2.0) - actionview (>= 6.0.0) - activemodel (>= 6.0.0) - bindex (>= 0.4.0) - railties (>= 6.0.0) webdrivers (5.0.0) nokogiri (~> 1.6) rubyzip (>= 1.3.0) @@ -419,7 +413,6 @@ DEPENDENCIES stimulus-rails turbo-rails tzinfo-data - web-console webdrivers RUBY VERSION diff --git a/app/assets/images/conference.jpg b/app/assets/images/conference.jpg new file mode 100644 index 00000000..e28a7448 Binary files /dev/null and b/app/assets/images/conference.jpg differ diff --git a/app/assets/images/developers.jpg b/app/assets/images/developers.jpg new file mode 100644 index 00000000..60034f99 Binary files /dev/null and b/app/assets/images/developers.jpg differ diff --git a/app/assets/stylesheets/application.tailwind.css b/app/assets/stylesheets/application.tailwind.css index c746599e..8f957b70 100644 --- a/app/assets/stylesheets/application.tailwind.css +++ b/app/assets/stylesheets/application.tailwind.css @@ -1,7 +1,10 @@ +@import url('https://fonts.googleapis.com/css2?family=Inter:wght@100..900&display=swap'); + @tailwind base; @tailwind components; @tailwind utilities; + @layer base { :root { /* Override colors and other variables */ @@ -9,6 +12,7 @@ } @layer components { + .turbo-progress-bar { background: linear-gradient(to right, hsl(var(--p)), hsl(var(--b1))); } diff --git a/app/helpers/chapters_helper.rb b/app/helpers/chapters_helper.rb index e7eb1e76..1a7c3d9f 100644 --- a/app/helpers/chapters_helper.rb +++ b/app/helpers/chapters_helper.rb @@ -1,4 +1,52 @@ # frozen_string_literal: true module ChaptersHelper + def activities + [ + { image: 'activities_local_meetups.png', title: 'Local meetups' }, + { image: 'activities_local_conferences.png', title: 'conferences' }, + { image: 'activities_local_programming.png', title: 'programming' }, + { image: 'activities_local_workshops.png', title: 'workshops' }, + { image: 'activities_local_hackathons.png', title: 'hackathons' } + ] + end + + def chapters + [ + { country: 'Kenya', image: 'country_kenya.png', alt: 'Nairuby' }, + { country: 'Rwanda', image: 'country_rwanda.png', alt: 'ARC_Rwanda' }, + { country: 'Tanzania', image: 'country_tanzania.png', alt: 'ARC_Tanzania' }, + { country: 'Uganda', image: 'country_uganda.png', alt: 'ARC_Uganda' } + ] + end + + def featured_sponsors + [ + { image: 'sponsors/current/nairobits.png', link: 'https://www.nairobits.com/', alt: 'Nairobits' }, + { image: 'sponsors/current/finplus.png', link: 'https://finplusgroup.com', alt: 'Finplus Group' } + ] + end + + def previous_sponsors + [ + { image: 'sponsors/previous/shopify.webp', link: 'https://www.shopify.com/', alt: 'Shopify' }, + { image: 'sponsors/previous/turing.png', link: 'https://www.turing.com/', alt: 'Turing' }, + { image: 'sponsors/previous/kopokopo.png', link: 'https://kopokopo.co.ke', alt: 'Kopokopo' }, + { image: 'sponsors/previous/kwara.png', link: 'https://kwara.com/', alt: 'Kwara' }, + { image: 'sponsors/previous/ihub.png', link: 'https://ihub.co.ke/', alt: 'iHub, Nairobi' }, + { image: 'sponsors/previous/andela.png', link: 'https://andela.com/', alt: 'Andela' } + ] + end + + def socials + [{ alt: 'ARC Twitter', link: 'https://twitter.com/ruby_african', image: 'brands_twitter.png', show: true }, + { alt: 'ARC telegram', link: '#', image: 'brands_telegram.png', + show: FeatureFlag.find_by(name: 'telegram').try(:enabled) }, + { alt: 'ARC facebook', link: 'https://www.facebook.com/rubycommunity.africa', + image: 'brands_facebook.png', show: true }, + { alt: 'ARC Instagram', link: '#', image: 'brands_instagram.png', show: true }, + { alt: 'ARC LinkedIn', link: 'https://www.linkedin.com/company/african-ruby-community/', + image: 'brands_linkedin.png', show: true }, + { alt: 'ARC Github', link: 'https://github.com/nairuby', image: 'brands_github.png', show: true }] + end end diff --git a/app/views/landing/home/_activities.html.erb b/app/views/landing/home/_activities.html.erb index 6dc30124..730a443c 100644 --- a/app/views/landing/home/_activities.html.erb +++ b/app/views/landing/home/_activities.html.erb @@ -1,31 +1,12 @@ -

+

Activities

-
-
- <%= image_tag image_path('activities_local_meetups.png'), alt: 'Local meetups photo' %> -

Local Meetups

-
- -
- <%= image_tag image_path('activities_local_conferences.png'), alt: 'Conferences photo' %> -

Conferences

-
- -
- <%= image_tag image_path('activities_local_programming.png'), alt: 'Programming photo' %> -

Programming

-
- -
- <%= image_tag image_path('activities_local_workshops.png'), alt: 'Workshops photo' %> -

Workshops

-
- -
- <%= image_tag image_path('activities_local_hackathons.png'), alt: 'Hackathons photo' %> -

Hackathons

-
+
+ <% activities.each do |activity| %> +
+ <%= image_tag activity[:image], alt: activity[:title], class: 'hover:scale-105' %> +

<%= activity[:title] %>

+
+ <% end %>
diff --git a/app/views/landing/home/_chapters.html.erb b/app/views/landing/home/_chapters.html.erb index 6517acba..5ecd9b7e 100644 --- a/app/views/landing/home/_chapters.html.erb +++ b/app/views/landing/home/_chapters.html.erb @@ -1,59 +1,20 @@
-

+

Chapters

-
-
- - <%= image_tag('country_kenya.png', alt: "Nairuby",class: 'pt-2 place-self-center h-16 md:36') %> -

Kenya

- - <%= link_to new_user_registration_path, class: 'place-self-center pb-6' do %> -

Join community

- <% end %> -
- -
- - <%= image_tag('country_rwanda.png', alt:"ARC_Rwanda", class: 'pt-2 place-self-center h-16 md:36') %> -

Rwanda

- - <%= link_to new_user_registration_path, class: 'place-self-center pb-6' do %> -

Join community

+
+ <% chapters. each do |chapter| %> + <%= link_to new_user_registration_path, class: 'place-self-center w-72 md:w-48 card border border-red-600 rounded flex flex-col gap-4 hover:scale-95 p-3' do %> + <%= image_tag chapter[:image], alt: chapter[:alt], class: 'pt-2 place-self-center h-16 md:36' %> +

<%= chapter[:country] %>

+

Join community

<% end %> -
- -
- - <%= image_tag('country_tanzania.png',alt:"ARC_Tanzania", class: 'pt-2 place-self-center h-16 md:36') %> -

Tanzania

- - <%= link_to new_user_registration_path, class: 'place-self-center pb-6' do %> -

Join community

- <% end %> -
- -
- - <%= image_tag('country_uganda.png',alt:"ARC_Uganda", class: 'pt-2 place-self-center h-16 md:36') %> -

Uganda

- - <%= link_to new_user_registration_path, class: 'place-self-center pb-6' do %> -

Join community

- <% end %> -
- - + <% end %> + <%= image_tag('add.png',alt:" Add Chapter",class: 'pt-2 place-self-center h-16 md:36') %> -

Request new chapter

+

Request new chapter

diff --git a/app/views/landing/home/_featured_sponsors.html.erb b/app/views/landing/home/_featured_sponsors.html.erb index 509ab3fd..ca6e39f4 100644 --- a/app/views/landing/home/_featured_sponsors.html.erb +++ b/app/views/landing/home/_featured_sponsors.html.erb @@ -2,16 +2,12 @@ Featured Sponsors -
- <%= link_to 'https://www.nairobits.com/', target: '_blank' do %> -
- <%= image_tag 'sponsors/current/nairobits.png', alt: "Nairobits" %> -
- <% end %> - - <%= link_to 'https://finplusgroup.com/', target: '_blank' do %> -
- <%= image_tag 'sponsors/current/finplus.png', alt: 'Finplus Group' %> -
+
+ <% featured_sponsors.each do |sponsor| %> + <%= link_to sponsor[:link], target: '_blank' do %> +
+ <%= image_tag sponsor[:image], alt: sponsor[:alt] %> +
+ <% end %> <% end %>
diff --git a/app/views/landing/home/_intro.html.erb b/app/views/landing/home/_intro.html.erb index 25141235..789ee4cc 100644 --- a/app/views/landing/home/_intro.html.erb +++ b/app/views/landing/home/_intro.html.erb @@ -1,89 +1,44 @@ -