osem
https://github.com/opensuse/osem
Ruby
Open Source Event Manager. An event management tool tailored to Free and Open Source Software conferences.
FormatHelper#contrast_color
Returns black or white deppending on what of them contrast more with the given color. Useful to print text in a coloured background. hexcolor is a hex color of 7 characters, being the first one '#'. Reference: https://24ways.org/2010/calculating-color-contrast
Edit
git clone [email protected]:opensuse/osem.git
cd osem
open app/helpers/format_helper.rb
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-FormatHelper-contrast_color-for-pr
# Commit to gitgit add app/helpers/format_helper.rbgit commit -m "better docs for FormatHelper#contrast_color"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-FormatHelper-contrast_color-for-pr
hub pull-request
# Celebrate!