{"id":20829803,"url":"https://github.com/devliusir/lcslidetounlock","last_synced_at":"2025-05-07T22:10:02.813Z","repository":{"id":56918284,"uuid":"122824618","full_name":"DevLiuSir/LCSlideToUnlock","owner":"DevLiuSir","description":"A simple slide to unlock iOS UI component.","archived":false,"fork":false,"pushed_at":"2020-10-16T13:53:39.000Z","size":4615,"stargazers_count":11,"open_issues_count":0,"forks_count":4,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-05-07T22:09:54.259Z","etag":null,"topics":["ios-animation","ios-demo","slider","slideshow","swift5-1","unlock","unlocker"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DevLiuSir.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-02-25T10:08:21.000Z","updated_at":"2024-12-29T08:22:58.000Z","dependencies_parsed_at":"2022-08-20T21:20:27.010Z","dependency_job_id":null,"html_url":"https://github.com/DevLiuSir/LCSlideToUnlock","commit_stats":null,"previous_names":["chinahackers/lcslidetounlock"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevLiuSir%2FLCSlideToUnlock","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevLiuSir%2FLCSlideToUnlock/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevLiuSir%2FLCSlideToUnlock/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevLiuSir%2FLCSlideToUnlock/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DevLiuSir","download_url":"https://codeload.github.com/DevLiuSir/LCSlideToUnlock/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252961841,"owners_count":21832197,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ios-animation","ios-demo","slider","slideshow","swift5-1","unlock","unlocker"],"created_at":"2024-11-17T23:22:09.612Z","updated_at":"2025-05-07T22:10:02.785Z","avatar_url":"https://github.com/DevLiuSir.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e \n\u003cimg  src=\"https://github.com/DevLiuSir/LCSlideToUnlock/raw/master/Screencast/LCSlideToUnlock.png\" width=\"500\" height=\"500\"\u003e\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e \u003cb\u003eLCSlideToUnlock is a simple slide to unlock iOS UI component.\u003c/b\u003e\u003c/p\u003e \n\n\n![language](https://img.shields.io/badge/language-swift-orange.svg)\n[![swift version](https://img.shields.io/badge/swift-5+-blue.svg?style=flat)](https://developer.apple.com/swift/)\n![xcode version](https://img.shields.io/badge/xcode-11+-red.svg)\n[![CocoaPods compatible](https://img.shields.io/cocoapods/v/LCSlideToUnlock.svg)](#cocoapods) \n![build state](https://img.shields.io/badge/build-passing-brightgreen)\n![GitHub top language](https://img.shields.io/github/languages/top/DevLiuSir/LCSlideToUnlock?color=blueviolet)\n![https://github.com/DevLiuSir/LCSlideToUnlock/blob/master/LICENSE](https://img.shields.io/github/license/DevLiuSir/LCSlideToUnlock.svg)\n![platform](https://img.shields.io/badge/platform-ios-lightgrey.svg)\n![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/DevLiuSir/LCSlideToUnlock?color=ff69b4\u0026label=codeSize)\n![commits count](https://badgen.net/github/commits/DevLiuSir/LCSlideToUnlock)\n![GitHub last commit](https://img.shields.io/github/last-commit/DevLiuSir/LCSlideToUnlock)\n![GitHub commit activity](https://img.shields.io/github/commit-activity/m/DevLiuSir/LCSlideToUnlock)\n![Github Star](https://img.shields.io/github/stars/DevLiuSir/LCSlideToUnlock.svg?style=social\u0026label=Star)\n![GitHub forks](https://img.shields.io/github/forks/DevLiuSir/LCSlideToUnlock?style=social)\n![GitHub watchers](https://img.shields.io/github/watchers/DevLiuSir/LCSlideToUnlock?style=social)\n[![Twitter Follow](https://img.shields.io/twitter/follow/LiuChuan_.svg?style=social)](https://twitter.com/LiuChuan_)\n\n\n---\n\n\n## Requirements\n\n- iOS 13+\n- Xcode 11+\n- Swift 5.1+\n\n## Screencast\n\n\u003cdiv align=center\u003e \n\u003cimg src=\"https://github.com/DevLiuSir/LCSlideToUnlock/raw/master/Screencast/Screencast02.png\" width=\"300\"\u003e\n\u003c/div\u003e\n\n\n## Effect of collection\n\n- **Using enumerations to define `LCSlideToUnlock` animation types**\n\n\n```swift\n/// 动画方向\n///\n/// - horizontal: 水平\n/// - vertical: 垂直\n/// - diagonalUp: 对角线往上\n/// - diagonalDown: 对角线往下\npublic enum AnimationDirection {\n    case horizontal\n    case vertical\n    case diagonalUp\n    case diagonalDown\n}\n```\n\n## Design\n\n| ![](https://github.com/DevLiuSir/LCSlideToUnlock/raw/master/Screencast/horizontal.gif) | ![](https://github.com/DevLiuSir/LCSlideToUnlock/raw/master/Screencast/vertical.gif) |  ![](https://github.com/DevLiuSir/LCSlideToUnlock/raw/master/Screencast/diagonalUp.gif) |  ![](https://github.com/DevLiuSir/LCSlideToUnlock/raw/master/Screencast/diagonalDown.gif) |\n| :------------: | :------------: | :------------: | :------------: |\n| `horizontal` | `vertical` | `diagonalUp`  | `diagonalDown` |\n\n\n## Attribute\n\n|  Attribute name\t|  Specific introduction of attributes\t|\n| :------------: | :------------: | \n|  `textStr `  |  LCSlideToUnlock  of  text  |\n|  `textColor`\t|  LCSlideToUnlock  text  color  |\n|  `isEnableAutoreverses`\t|  Whether to turn on and back animation  |\n|  `shimmerImage`  | Gradient picture (You can only set one with `shimmerColors`) |\n|  `shimmerColors`  |  The gradient color group (at least two elements, only one with `shimmerImage`)\t|\n\n\n## Installation\n\n[CocoaPods](http://cocoapods.org/) is a dependency manager for Cocoa projects. You can install it with the following command:\n\n```swift\n$ gem install cocoapods\n```\n\n\nJust add the `LCSlideToUnlock` folder to your project.\n\nor use `CocoaPods` with Podfile:\n\n```swift\npod 'LCSlideToUnlock'\n```\n\nYou can use CocoaPods to install `LCSlideToUnlock` by adding it to your Podfile:\n\n\n```swift\nplatform :ios, '12.0'\ntarget '\u003cYour Target Name\u003e' do\nuse_frameworks!\npod 'LCSlideToUnlock'\nend\n```\n\n\n\nThen, run the following command:\n\n```swift\n$ pod install\n```\n\n\n## Example:\n\n```swift\nimport UIKit\nimport LCSlideToUnlock\n\nclass ViewController: UIViewController {\n    override func viewDidLoad() {\n        super.viewDidLoad()\n        /******* LCSlideToUnlockView *******/\n        let slideToUnlockView = LCSlideToUnlockView(frame: CGRect(x: 0, y: view.bounds.height - 100, width: view.bounds.width, height: 40))\n        slideToUnlockView.textStr = \"\u003e Slide To Unlock \"\n        slideToUnlockView.textColor = .black\n        slideToUnlockView.shimmerColors = [.white, .white]\n        //slideToUnlockView.shimmerImage = UIImage(named: \"gradient\")\n        slideToUnlockView.font = UIFont.systemFont(ofSize: 20)\n        slideToUnlockView.animationDirection = .horizontal\n        slideToUnlockView.isEnableAutoreverses = false\n        slideToUnlockView.showFadeWithDuration(4)\n        view.addSubview(slideToUnlockView)\n    }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevliusir%2Flcslidetounlock","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevliusir%2Flcslidetounlock","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevliusir%2Flcslidetounlock/lists"}