Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Enable Passwords Autofill #170

Open
Krillle opened this issue Apr 12, 2024 · 4 comments
Open

Feature Request: Enable Passwords Autofill #170

Krillle opened this issue Apr 12, 2024 · 4 comments

Comments

@Krillle
Copy link
Contributor

Krillle commented Apr 12, 2024

It would be nice, if the public class TeslaWebLoginViewController would trigger the Safari AutoFill option to fill out passwords automatically. It might work with something like this:

init(url: URL) {
      super.init(nibName: nil, bundle: nil)

      // Enable AutoFill Passwords 
      let config = WKWebViewConfiguration()
      config.websiteDataStore = WKWebsiteDataStore.default()      
      webView = WKWebView(frame: .zero, configuration: config)
      
      webView.navigationDelegate = self
      webView.load(URLRequest(url: url))
  }

@jonasman
Copy link
Owner

can you make a PR?

the alternative is to use the native browser, that the lib already supports

@Krillle
Copy link
Contributor Author

Krillle commented Apr 12, 2024

I have the changes here in this Patch-4, but this alone was not triggering the AutoFill.

Btw how to get the TeslaSwiftDemo project running on simulator? I cant find a matching target to run.

@Krillle
Copy link
Contributor Author

Krillle commented Apr 12, 2024

@jonasman how to use the native browser for Tesla login?

@jonasman
Copy link
Owner

jonasman commented Aug 7, 2024

@Krillle you need to open Safari for login, there is a method to get you the URL.
then you need to support a deeplink in your app for the Tesla website to open your app again.
You must register with Tesla Dev portal that deeplink and then in Xcode.

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

No branches or pull requests

2 participants