         }
         
     }
-    
 }
+
+// MARK: - Action
+extension LoginViewController{
+    @IBAction func fbButtonTapped(sender: UIButton) {
+        let login = FBSDKLoginManager()
+        login.logInWithReadPermissions(["public_profile", "email"], fromViewController: self, handler: { (result,error) -> Void in
+            if error != nil{
+                print(error.localizedDescription)
+                return
+            }else if result.isCancelled{
+                return
+            }else{
+                self.login()
+                print(FBSDKAccessToken.currentAccessToken())
+            }
+        })
+    }
+}
+

        weightTextField.text = "Please enter your weight"
        
    }
    
    func textFieldDidBeginEditing(textField: UITextField) {
        heightTextField.textColor = UIColor.mrDarkSlateBlueColor()
        weightTextField.textColor = UIColor.mrDarkSlateBlueColor()

import FBSDKLoginKit
import FBSDKShareKit

class LoginViewController: UIViewController{
    @IBOutlet weak var loginButton: UIButton!
    @IBOutlet weak var heightTextField: UITextField!
    @IBOutlet weak var weightTextField: UITextField!
}

// MARK: - Setup
extension LoginViewController{
    func setupBackground(){
        let gradientLayer = CAGradientLayer()
        gradientLayer.colors = [UIColor.mrLightblueColor().CGColor, UIColor.mrPineGreen50Color().CGColor]
