{"id":15067013,"url":"https://github.com/saeid/gdtextslot","last_synced_at":"2025-08-09T23:35:11.998Z","repository":{"id":56911943,"uuid":"122326875","full_name":"saeid/GDTextSlot","owner":"saeid","description":"Simple component for code input texts and character / digits slots","archived":false,"fork":false,"pushed_at":"2020-04-19T10:51:39.000Z","size":17,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-17T16:36:04.817Z","etag":null,"topics":["code","ios","placeholder","storyboard","swift4"],"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/saeid.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-21T11:18:41.000Z","updated_at":"2022-07-17T09:44:11.000Z","dependencies_parsed_at":"2022-08-21T03:20:12.542Z","dependency_job_id":null,"html_url":"https://github.com/saeid/GDTextSlot","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/saeid/GDTextSlot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saeid%2FGDTextSlot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saeid%2FGDTextSlot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saeid%2FGDTextSlot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saeid%2FGDTextSlot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saeid","download_url":"https://codeload.github.com/saeid/GDTextSlot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saeid%2FGDTextSlot/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269653956,"owners_count":24454317,"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","status":"online","status_checked_at":"2025-08-09T02:00:10.424Z","response_time":111,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["code","ios","placeholder","storyboard","swift4"],"created_at":"2024-09-25T01:15:12.499Z","updated_at":"2025-08-09T23:35:11.948Z","avatar_url":"https://github.com/saeid.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GDTextSlot\nA customizable control for code/text input. Easy setup with Storyboard and attributes inspector or Code.\n\n![slotview](https://user-images.githubusercontent.com/9967486/36479624-625fbe3c-171a-11e8-8f9e-4c39ee0f4f8d.gif)\n\n------\n------\n\n### Requirments\n- Xcode 9+\n- Swift 5\n- iOS 9+\n-----\n\n# Installation\n## Manual\ndrag `GDTextSlot.swift` to your project!\n\n## Cocoapods\n```\nsource 'https://github.com/CocoaPods/Specs.git'\nplatform :ios, '9.0'\nuse_frameworks!\n\ntarget '\u003cYour Target Name\u003e' do\n    pod 'GDTextSlot'\nend\n```\n    pod install\n\n\n# Usage\n\n## Code\n```swift\nlet frame = CGRect(x: 0, y: 0, width: 300, height: 60)\nlet slotView = GDTextSlot(frame: frame)\nslotView.delegate = self\nview.addSubview(slotView)\n```\n\nSet Properties\n```swift\n// Automatically activate text slot and show keyboard\n// Or it will be activated when it's tapped\nslotView.becomeFirstResponder()\n\n// Set keyboard type -- Default is .numberPad\nslotView.keyboard = .default\n\n// Set number of slots -- Default is 4\nslotView.numberOfSlots = 6\n\n// Set space between slots -- Default is 50\nslotView.baseWidth = 40\n\n// Set text slot placeholder. Default is ___\nslotView.placeholder = *\n\n// Set custom font for the text\nslotView.textFont = UIFont\n```\n\nConform to `GDTextSlotDelegate`\n\n```swift\nfunc onTextEntered(_ slotView: GDTextSlot, _ finalText: String){\n    print(finalText)\n}\n```\n\n## Storyboard\n1) Add a `UIView` and set its custom class to `GDTextSlot`\n2) Set attributes with `Attributes inspector`\n\nRun!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaeid%2Fgdtextslot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaeid%2Fgdtextslot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaeid%2Fgdtextslot/lists"}