{"action":"created","issue":{"url":"https://api.github.com/repos/halostatue/color/issues/17","labels_url":"https://api.github.com/repos/halostatue/color/issues/17/labels{/name}","comments_url":"https://api.github.com/repos/halostatue/color/issues/17/comments","events_url":"https://api.github.com/repos/halostatue/color/issues/17/events","html_url":"https://github.com/halostatue/color/issues/17","id":55311811,"number":17,"title":"Using Contrast Methods","user":{"login":"nucleogenesis","id":6356129,"avatar_url":"https://avatars.githubusercontent.com/u/6356129?v=3","gravatar_id":"","url":"https://api.github.com/users/nucleogenesis","html_url":"https://github.com/nucleogenesis","followers_url":"https://api.github.com/users/nucleogenesis/followers","following_url":"https://api.github.com/users/nucleogenesis/following{/other_user}","gists_url":"https://api.github.com/users/nucleogenesis/gists{/gist_id}","starred_url":"https://api.github.com/users/nucleogenesis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nucleogenesis/subscriptions","organizations_url":"https://api.github.com/users/nucleogenesis/orgs","repos_url":"https://api.github.com/users/nucleogenesis/repos","events_url":"https://api.github.com/users/nucleogenesis/events{/privacy}","received_events_url":"https://api.github.com/users/nucleogenesis/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-23T17:58:09Z","updated_at":"2015-01-23T18:17:34Z","closed_at":null,"body":"Firstly, thanks for this Gem, it has helped a lot with a current project!\r\n\r\nI may not have a full grasp of how Gems are packaged or something, so I have a few questions.\r\n\r\nIs there a reason that the methods in `lib/color/rgb/contrast.rb` aren't available in the current Gem? Is it because it is in a subdirectory to where the `class Color::RGB` is defined? Or that the file doesn't have the `include Color` line?\r\n\r\nWhen I try to use the method like follows, I get an undefined method error for `contrast`.\r\n\r\n```\r\nirb(main):006:0> Color::RGB.by_css('ffffff').contrast(Color::RGB.by_css('000000'))\r\nNoMethodError: undefined method `contrast' for RGB [#ffffff]:Color::RGB\r\n\tfrom (irb):6\r\n\tfrom /home/jacob/.rvm/rubies/ruby-2.1.0/bin/irb:11:in `<main>'\r\n```\r\n\r\nI forked the repo and just copied the methods from `contrast.rb` into `rgb.rb`, added my git repo to my Gemfile in a rails project and the methods seem to work excellently. See [this commit] (https://github.com/nucleogenesis/color/commit/dd7b4ce4d36b5fab20b9dc3e06901ae0688a147c) in my fork. I use the contrast method and it works great.\r\n\r\nJust wondering if maybe I'm missing something on how it is supposed to be used, or if it isn't ready for production due to a lack of tests or something. For now, I'll use my fork, and again, thank you to everybody who has helped with this Gem!\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/halostatue/color/issues/comments/71237872","html_url":"https://github.com/halostatue/color/issues/17#issuecomment-71237872","issue_url":"https://api.github.com/repos/halostatue/color/issues/17","id":71237872,"user":{"login":"halostatue","id":11361,"avatar_url":"https://avatars.githubusercontent.com/u/11361?v=3","gravatar_id":"","url":"https://api.github.com/users/halostatue","html_url":"https://github.com/halostatue","followers_url":"https://api.github.com/users/halostatue/followers","following_url":"https://api.github.com/users/halostatue/following{/other_user}","gists_url":"https://api.github.com/users/halostatue/gists{/gist_id}","starred_url":"https://api.github.com/users/halostatue/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/halostatue/subscriptions","organizations_url":"https://api.github.com/users/halostatue/orgs","repos_url":"https://api.github.com/users/halostatue/repos","events_url":"https://api.github.com/users/halostatue/events{/privacy}","received_events_url":"https://api.github.com/users/halostatue/received_events","type":"User","site_admin":false},"created_at":"2015-01-23T18:17:34Z","updated_at":"2015-01-23T18:17:34Z","body":"If I remember correctly, this was intentional—the methods were considered experimental pending further reflection, so that if you need the contrast methods, you just `require 'color/rgb/contrast'`."}}