{"id":21820302,"url":"https://github.com/trademe/keyboarddodger","last_synced_at":"2025-04-14T02:45:00.134Z","repository":{"id":56917870,"uuid":"91028439","full_name":"TradeMe/KeyboardDodger","owner":"TradeMe","description":"An iOS cocoapod that uses a constraint to move a view out of the way of the on-screen keyboard.","archived":false,"fork":false,"pushed_at":"2019-06-17T22:47:03.000Z","size":21,"stargazers_count":4,"open_issues_count":0,"forks_count":3,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-04-11T05:18:27.147Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/TradeMe.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":"2017-05-11T22:24:43.000Z","updated_at":"2020-08-28T02:46:39.000Z","dependencies_parsed_at":"2022-08-20T21:20:33.824Z","dependency_job_id":null,"html_url":"https://github.com/TradeMe/KeyboardDodger","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TradeMe%2FKeyboardDodger","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TradeMe%2FKeyboardDodger/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TradeMe%2FKeyboardDodger/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TradeMe%2FKeyboardDodger/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TradeMe","download_url":"https://codeload.github.com/TradeMe/KeyboardDodger/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248812873,"owners_count":21165499,"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":[],"created_at":"2024-11-27T16:31:14.125Z","updated_at":"2025-04-14T02:45:00.114Z","avatar_url":"https://github.com/TradeMe.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"## KeyboardDodger\n\nKeyboardDodger is an iOS cocoapod that uses a constraint to move a view out of the way of the on-screen keyboard.\n\n### Installation\n\n```ruby\npod 'KeyboardDodger', '~\u003e 1.0'\n```\n\n### Usage\n\nKeyboardDodger attaches to a view and a constraint at the bottom of the view, and manipulates the constraint to keep it out of the way of the on-screen keyboard.\n\nAn example implementation:\n\n```swift\nclass ViewController: UIViewController {\n\n    var bottomConstraint: NSLayoutConstraint?\n\n    var keyboardDodger: KeyboardDodger?\n\n    override func viewDidLoad() {\n        super.viewDidLoad()\n\n        if let bottomConstraint = bottomConstraint {\n            keyboardDodger = KeyboardDodger(view: view, constraint: bottomConstraint, delegate: self)\n        }\n    }\n\n}\n\nextension ViewController: KeyboardDodgerDelegate {\n    \n    func keyboardDodger(_ keyboardDodger: KeyboardDodger, willUpdateConstraintWith transition: KeyboardDodgerTransition) {\n        print(\"Keyboard dodger will update constraint\")\n    }\n    \n    func keyboardDodger(_ keyboardDodger: KeyboardDodger, didUpdateConstraintWith transition: KeyboardDodgerTransition) {\n        print(\"Keyboard dodger did update constraint\")\n    }\n    \n    func keyboardDodger(_ keyboardDodger: KeyboardDodger, willResetConstraintWith transition: KeyboardDodgerTransition) {\n        print(\"Keyboard dodger will reset constraint\")\n    }\n    \n    func keyboardDodger(_ keyboardDodger: KeyboardDodger, didResetConstraintWith transition: KeyboardDodgerTransition) {\n        print(\"Keyboard dodger did reset constraint\")\n    }\n\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrademe%2Fkeyboarddodger","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftrademe%2Fkeyboarddodger","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrademe%2Fkeyboarddodger/lists"}