Sha256: 6309bdd4f96a2dae397aa7b069689121733a41b3435fdfc3158397c1bb1290db

Contents?: true

Size: 652 Bytes

Versions: 2

Compression:

Stored size: 652 Bytes

Contents

module Socialite
  module Helpers
    module Authentication
      def identity_request_path(options={})
        [Socialite.mount_prefix, 'auth', options[:service]].join('/')
      end

      def twitter_login_button
        content_tag(:a, content_tag(:span, 'Sign in with Twitter'), :class => 'socialite_button twitter', :href => identity_request_path(:service => 'twitter'), :rel => 'external')
      end

      def facebook_login_button
        content_tag(:a, content_tag(:span, 'Sign in with Facebook'), :class => 'socialite_button facebook', :href => identity_request_path(:service => 'facebook'), :rel => 'external')
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
socialite-0.0.1.beta4 lib/socialite/helpers/authentication.rb
socialite-0.0.1.beta2 lib/socialite/helpers/authentication.rb