Skip to content

Commit

Permalink
Reorgannized badges image files structure
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre-Henri Symoneaux committed Oct 24, 2017
1 parent 277bb2e commit cdb90da
Show file tree
Hide file tree
Showing 11 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions lib/leaderboard.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ def earned_by?(player)
end

BADGES = [
Badge.new('medal', 'Completed hacktoberfest', 'The player completed the hacktoberfest challenge by submitting 4 pull requests', &:challenge_complete?),
Badge.new('snake', 'Snake charmer', 'The player submitted at least 1 PR to the snake game', &:contributed_to_snake?),
Badge.new('leaderboard', 'Leaderboard contributor', 'The player submitted at least 1 PR to the leaderboard code', &:contributed_to_leaderboard?),
Badge.new('10-contributions', 'Pull Request champion', 'The player submitted more than 10 Pull requests', &:ten_contributions?),
Badge.new('adventure', 'Adventurer', 'The player submitted at least 1 PR to a repository out of "ourtigarage" organisation', &:contributed_out_of_org?),
Badge.new('hacktoberfest', 'Hacktoberfest completed', 'Completed the hacktoberfest challenge by submitting 4 pull requests', &:challenge_complete?),
Badge.new('snake', 'The snake charmer', 'Submitted 1 Pull Request to the <a href="https://ourtigarage.github.io/web-snake/">snake game</a>\'s code repository', &:contributed_to_snake?),
Badge.new('leaderboard', 'The leaderboard contributor', 'Submitted 1 Pull Request to this leaderboard\'s code repository', &:contributed_to_leaderboard?),
Badge.new('10-contributions', 'The Pull Request champion', 'Submitted more than 10 Pull requests', &:ten_contributions?),
Badge.new('adventure', 'The adventurer', 'Submitted 1 Pull Request to a repository out of <a href="https://github.com/ourtigarage">ourtigarage</a> organisation', &:contributed_out_of_org?),
Badge.new('novelist', 'The novelist', 'Wrote more than 100 words in a Pull Request\'s description', &:contribution_with_100_words?),
Badge.new('taciturn', 'The taciturn', 'Submitted a Pul Request with no description', &:contribution_with_no_word?)
Badge.new('taciturn', 'The taciturn', 'Submitted a Pull Request with no description', &:contribution_with_no_word?)
].freeze

# The leaderboard root class, where the magic happens
Expand Down
File renamed without changes
File renamed without changes
File renamed without changes
Binary file added static/img/badges/hacktoberfest.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
2 changes: 1 addition & 1 deletion views/index.erb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
<% for badge in member.badges %>
<div class="popover popover-right">
<figure class="avatar avatar-xl">
<img src="img/<%=badge.short%>.png" alt="<%=badge.short%>">
<img src="img/badges/<%=badge.short%>.png" alt="<%=badge.short%>">
</figure>
<div class="popover-container">
<div class="card">
Expand Down

0 comments on commit cdb90da

Please sign in to comment.