railsfrance/railsfrance.org

View on GitHub
app/views/home/index.html.haml

Summary

Maintainability
Test Coverage
- set_meta_tags title: "RailsFrance.org | La communauté francophone des utilisateurs de Ruby On Rails", 
description: "Questions, offres d'emplois, événements, Ruby On Rails, France"

%section#homeSection.worldMap
  %header#homeHeader
    %ul
      %li
        = link_to resources_path(anchor: "discover"), id: "discoverRuby" do
          %span
            Découvrir
          %br
          Ruby on Rails     
      %li
        = link_to resources_path(anchor: "download"), id: "downloadRuby" do
          %span
            Télécharger
          %br
          Ruby on Rails
      %li
        = link_to resources_path(anchor: "learn"), id: "learnRuby" do
          %span
            Apprendre
          %br
          à développer
      %li
        = link_to resources_path(anchor: "community"), id: "contributeRuby" do
          %span
            Contribuer
          %br
          à la communauté
  #homeHgroup
    = link_to "Rails", "http://rubyonrails.org/", target: "_blank"
    %div
      %h1
        Bienvenue sur le portail francophone de la communauté Ruby on Rails
      %p
        Vous trouverez ici toutes les ressources nécessaires pour débuter avec Ruby on Rails et partager avec sa communauté française.
  #homeContent
    #homeEvents.homeContent
      %h2
        Les évènements Rails
      %ul
        - @presenter.recent_events.each do |event|
          %li
            %article
              %h3
                = link_to truncate(event.title, length: 35), event_path(event)
              %p
                = truncate(sanitize(event.description), length: 100).html_safe
      = link_to "Voir tous les évènements", events_path, class: "smallButton"
    #homeJobs.homeContent
      %h2
        Les Jobs Rails
      %ul
        - @presenter.recent_jobs.each do |job|
          %li
            %article
              %h3
                = link_to truncate(job.title, length: 35), job_path(job)
              %p
                = truncate(sanitize(job.description), length: 100).html_safe 
      = link_to "Voir tous les Jobs", jobs_path, class: "smallButton"
    #homeTweets.homeContent
      %h2
        Les Derniers Tweets
      %ul
        - @presenter.recent_tweet.each do |tweet|
          %li
            %p
              = tweet['text']
              %br
              %span= "{ Il y a #{distance_of_time_in_words tweet['created_at'].to_time, Time.now} }"
      = link_to  "Accéder au Twitter", "http://twitter.com/#{Settings.twitter.account}", target: "_blank", class: "smallButton"
    %h4
      Les projets sur les rails
    %ul#railsProjectSlider
      - @presenter.rails_projects.each do |project|
        %li
          = link_to image_tag("home/caroussel/#{project[:img]}"), project[:link], title: project[:title], target: "_blank"