Code Monkey home page Code Monkey logo

localauthenticationkit's Introduction

LocalAuthenticationKit

Swift Package Manager GitHub stars GitHub forks GitHub contributors Pull Requests Badge Issues Badge

Description

LocalAuthenticationKit is a SwiftUI library for handling local authentication.


Requirements

  • iOS: 17.0 or later.
  • macOS: 14.0 or later.

Installation

You can install LocalAuthenticationKit using the Swift Package Manager.

  1. In Xcode, select "File" > "Add Package Dependencies".
  2. Copy & paste the following into the "Search or Enter Package URL" search bar.
https://github.com/JamesSedlacek/LocalAuthenticationKit.git
  1. Xcode will fetch the repository & the "LocalAuthenticationKit" library will be added to your project.

Usage

  1. Add .authenticateIfEnabled() to the root view in your project.
import LocalAuthenticationKit
import SwiftUI

@main
struct ExampleApp: App {
    var body: some Scene {
        ContentView()
            .authenticateIfEnabled()
    }
}

  1. Use a LocalAuthToggle() in the settings screen in your project.
import LocalAuthenticationKit
import SwiftUI

struct SettingsView {
    var body: some View {
        VStack {
            LocalAuthToggle()
        }
    }
}

Author

James Sedlacek, find me on X/Twitter or LinkedIn

localauthenticationkit's People

Contributors

jamessedlacek avatar

Stargazers

 avatar Aisultan avatar Yuto Iwakami avatar Artem F avatar Yoshiro MORIYAMA avatar Francisco Huchin avatar Basel Baragabah avatar Timo avatar Mahmoud Aoata avatar Vinicius Pimenta avatar Peter Salz avatar lichunfei avatar Brett G avatar Tibin Thomas avatar NF avatar  avatar Marlon Raskin avatar  avatar WenDao avatar Gray Zhang avatar Filippos Sakellaropoulos avatar Fernando Lemler Cani avatar Eric kogi avatar Chirag N Shah avatar Hanh Q. Vu avatar  avatar László avatar Jota Uribe avatar Stephan Deumier avatar iankoex avatar Stef Kors avatar Nikhil Nigade avatar Femi Aliu avatar Deathwink avatar Filip Stefansson avatar Erdal avatar Damiano Plebani avatar Covalent avatar Joel avatar Armin Shalchian avatar Gavin avatar Murad avatar narakai avatar Andrew Zheng avatar Markus Lanxinger avatar Alexandru Ștefan avatar Seif Kobrosly avatar

Watchers

 avatar Peter Salz avatar  avatar

localauthenticationkit's Issues

Text customizations

Allow for the developer to set the localizedReason when evaluating policy in the authenticate() function.

Allow for the developer to set the localizedCancelTitle.

Lock icon not showing

The lock Icon and the text that is shown in the example screenshots (left of the button) is not displaying.
Tested on physical device (iPhone 13 mini)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.