{"id":31135767,"url":"https://github.com/jjessel/jhtalertcontroller","last_synced_at":"2026-03-11T12:15:29.151Z","repository":{"id":37677387,"uuid":"74076115","full_name":"jjessel/JHTAlertController","owner":"jjessel","description":"A custom iOS alert that replaces the stock UIAlertController. Easily style the alert to match your app. Written in Swift for iOS.  ","archived":false,"fork":false,"pushed_at":"2019-07-11T09:48:52.000Z","size":5457,"stargazers_count":58,"open_issues_count":7,"forks_count":26,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-09-16T06:56:05.156Z","etag":null,"topics":["alert","alertcontroller","carthage","cocoapods","custom","ios","modal","swift","uialertcontroller","uialertview","warning"],"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/jjessel.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2016-11-17T23:21:09.000Z","updated_at":"2025-02-27T05:15:20.000Z","dependencies_parsed_at":"2022-08-20T21:20:19.575Z","dependency_job_id":null,"html_url":"https://github.com/jjessel/JHTAlertController","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"purl":"pkg:github/jjessel/JHTAlertController","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjessel%2FJHTAlertController","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjessel%2FJHTAlertController/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjessel%2FJHTAlertController/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjessel%2FJHTAlertController/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jjessel","download_url":"https://codeload.github.com/jjessel/JHTAlertController/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jjessel%2FJHTAlertController/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":275725632,"owners_count":25516775,"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-09-18T02:00:09.552Z","response_time":77,"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":["alert","alertcontroller","carthage","cocoapods","custom","ios","modal","swift","uialertcontroller","uialertview","warning"],"created_at":"2025-09-18T07:08:27.039Z","updated_at":"2025-09-18T07:08:31.336Z","avatar_url":"https://github.com/jjessel.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JHTAlertController\n\n[![Version](https://img.shields.io/cocoapods/v/JHTAlertController.svg?style=flat)](http://cocoapods.org/pods/JHTAlertController)\n[![License](https://img.shields.io/cocoapods/l/JHTAlertController.svg?style=flat)](http://cocoapods.org/pods/JHTAlertController/blob/master/LICENSE)\n[![Platform](https://img.shields.io/cocoapods/p/JHTAlertController.svg?style=flat)](http://cocoapods.org/pods/JHTAlertController)\n[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage)\n\n![alt tag](https://github.com/jjessel/JHTAlertController/blob/master/img/dark.PNG)\n![alt tag](https://github.com/jjessel/JHTAlertController/blob/master/img/light.PNG)\n![alt tag](https://github.com/jjessel/JHTAlertController/blob/master/img/icon.PNG)\n\n## Easy to use\nJHTAlertController is an easy to use replacement for `UIAlertController`. You can customize the appearance of your alert to match the theme of your app.\n\n```swift\n// Setting up an alert with a title and message\nlet alertController = JHTAlertController(title: \"Turtle\", message: \"In this alert we use a String for the title instead of an image.\", preferredStyle: .alert)\n\n// Create the action.\nlet cancelAction = JHTAlertAction(title: \"Cancel\", style: .cancel,  handler: nil)\n\n// Create an action with a completionl handler.\nlet okAction = JHTAlertAction(title: \"Ok\", style: .default) { _ in\n   print(\"Do something here!\")\n}\n\n// Add the actions to the alert.\nalertController.addAction(cancelAction)\nalertController.addAction(okAction)\n\n// Show the action\npresent(alertController, animated: true, completion: nil)\n```\n\n## Customize the Appearance\n\n* Change Fonts\n* Change Colors\n* Add Icons\n\n\n#### Alert\n```swift\n// Change the background color\nalertController.alertBackgroundColor = .black\n\n// Round the corners\nalertController.hasRoundedCorners = true\n```\n#### Title Block \n```swift\n// Use an image instead of text\nalertController.titleImage = UIImage(named: \"Turtle\")\n// If you add an image to the title block, you may need to set restrictTitleViewHeight to true, depending on the image size\n\n// Change the color of the text\nalertController.titleTextColor = .black\n\n// Change the font\nalertController.titleFont = .systemFont(ofSize: 18)\n\n// Change the title block color\nalertController.titleViewBackgroundColor = .black\n\n// Add an icon image to the title block\nlet alertController = JHTAlertController(title: \"Wow!\", message: \"You can even set an icon for the alert.\", preferredStyle: .alert, iconImage: UIImage(named: \"TurtleDark\"))\n```\n#### Message \n```swift\n// Change the font\nalertController.messageFont = .systemFont(ofSize: 18)\n\n/ Change thte text color\nalertController.messageTextColor = .black\n```\n#### Button\n```swift\n// Change the color of the divider\nalertController.dividerColor = .black\n\n// Change the color of the button during the creation of the action\nlet blueAction = JHTAlertAction(title: \"Blue\", style: .default, bgColor: .blue, handler: nil)\n\n// Change the color for all buttons of a specific action\nalertController.setButtonBackgroundColorFor(.default, to: .blue)\n\n// Change the text color for a specific action\nalertController.setButtonTextColorFor(.default, to: .white)\n\n// Change the font for a specific action\nalertController.setButtonFontFor(.default, to: .systemFont(ofSize: 18))\n\n// Change all action types to a specific color\nalertController.setAllButtonBackgroundColors(to: .blue)\n```\n\n## Example\n\nTo run the example project, clone the repo, and run `pod install` from the Example directory first.\n\n## Requirements\niOS 9.0 and higher\n\n## Installation\n\n### CocoaPods\nJHTAlertController is available through [CocoaPods](http://cocoapods.org). To install\nit, simply add the following line to your Podfile:\n\n```ruby\npod \"JHTAlertController\"\n```\n### Carthage\n[Carthage](https://github.com/Carthage/Carthage) is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks.\n\nYou can install Carthage using Homebrew:\n```\n$ brew update\n$ brew install carthage\n```\nTo add JHTAlertController to your Xcode project using Carthage, update your Cartfile:\n```\ngithub \"jjessel/JHTAlertController\" ~\u003e 0.2.4\n```\nRun ```carthage update``` to build the framework and drag the built JHTAlertController.framework into your Xcode project.\n\n## Author\n\nJeremiah Jessel @ Jacuzzi Hot Tubs, LLC\n\n## License\n\nJHTAlertController is available under the MIT license. See the LICENSE file for more info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjjessel%2Fjhtalertcontroller","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjjessel%2Fjhtalertcontroller","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjjessel%2Fjhtalertcontroller/lists"}