Skip to content

Conversation

@jleandroperez
Copy link
Contributor

@jleandroperez jleandroperez commented May 25, 2018

Details:

  • This PR implements the Login Prologue UI

Testing:

  1. Fresh install WC
  2. Verify the Prologue shows up onscreen!
  3. Press the Login button
  4. Verify the WPAuth flow kicks in

NOTE: Let's update the asset in another PR when it's ready!

cc @mindgraffiti

let defaultTextColor = UIColor.black
let sectionTitleColor = UIColor.darkGray
let buttonPrimaryColor = UIColor(red: 0x96/255.0, green: 0x58/255.0, blue: 0x8A/255.0, alpha: 0xFF/255.0)
let buttonPrimaryHighlightedColor = UIColor(red: 0x6E/255.0, green: 0x29/255.0, blue: 0x67/255.0, alpha:0xFF/255.0)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Colon Violation: Colons should be next to the identifier when specifying a type and next to the key in dictionary literals. (colon)


/// WooCommerce UIImage Assets
///
extension UIImage {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Opening Brace Spacing Violation: Opening braces should be preceded by a single space and on the same line as the declaration. (opening_brace)

@nheagy
Copy link

nheagy commented May 28, 2018

What does it look like?

@jleandroperez
Copy link
Contributor Author

@nheagy not ready yet! i need to bug Davide with few metrics, but currently, looks like this on the iPhone SE: (adding the Shadow on top of the bottom white view right now)

simulator screen shot - iphone se - 2018-05-28 at 14 25 55

@nheagy
Copy link

nheagy commented May 28, 2018

Cool!

@jleandroperez
Copy link
Contributor Author

Thank you @nheagy, work in progress actually!! 😄

@jleandroperez jleandroperez added this to the Internal alpha release milestone May 29, 2018
Copy link
Contributor

@mindgraffiti mindgraffiti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A small bugfix and then :shipit: sir :)

@IBOutlet var loginButton: UIButton!


// MARK: - Overriden Properties
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overridden instead of Overriden

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MY GOD i may have been misspelling that forever!! thank you Thuy!!!

}


// MARK: - Overriden Methods
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here


/// Opens SafariViewController at the specified URL.
///
func displaySafariViewController(at url: URL) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because of our AppDelegate settings, the Safari VC gets a white status bar. To fix it, add this:

extension SFSafariViewController {
    override open func viewWillAppear(_ animated: Bool) {
        super.viewWillAppear(true)
        UIApplication.shared.statusBarStyle = .default
    }

    override open func viewWillDisappear(_ animated: Bool) {
        super.viewWillDisappear(true)
        UIApplication.shared.statusBarStyle = .lightContent
    }
}

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for bringing this up!! i've, instead, added SafariViewController (SFSafariViewController subclass), that would give us extra flexibility (just a few LOC's).

@jleandroperez jleandroperez merged commit e3bc7ad into develop May 30, 2018
@jleandroperez jleandroperez deleted the issue/22-woo-prologue branch May 30, 2018 13:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants