{"id":18538142,"url":"https://github.com/githawkapp/dropdowntitleview","last_synced_at":"2026-03-08T16:01:55.925Z","repository":{"id":56908789,"uuid":"154040480","full_name":"GitHawkApp/DropdownTitleView","owner":"GitHawkApp","description":"A UINavigationItem.titleView compatible UIControl with a title, subtitle, and dropdown.","archived":false,"fork":false,"pushed_at":"2020-02-01T21:39:50.000Z","size":220,"stargazers_count":254,"open_issues_count":1,"forks_count":13,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-24T08:18:44.313Z","etag":null,"topics":["githawk"],"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/GitHawkApp.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-10-21T18:39:50.000Z","updated_at":"2025-02-18T14:12:51.000Z","dependencies_parsed_at":"2022-08-21T01:50:57.529Z","dependency_job_id":null,"html_url":"https://github.com/GitHawkApp/DropdownTitleView","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitHawkApp%2FDropdownTitleView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitHawkApp%2FDropdownTitleView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitHawkApp%2FDropdownTitleView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GitHawkApp%2FDropdownTitleView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GitHawkApp","download_url":"https://codeload.github.com/GitHawkApp/DropdownTitleView/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246922247,"owners_count":20855345,"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":["githawk"],"created_at":"2024-11-06T19:42:30.994Z","updated_at":"2026-03-08T16:01:55.849Z","avatar_url":"https://github.com/GitHawkApp.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DropdownTitleView\n\nA simple and configurable \"dropdown\" view built for `UINavigationItem.titleView`.\n\n## Installation\n\nJust add `DropdownTitleView` to your Podfile and pod install. Done!\n\n```\npod 'DropdownTitleView'\n```\n\n## Usage\n\nCreate an instance of `DropdownTitleView`, configure it, and set it as a `UINavigationItem`'s `titleView`:\n\n```swift\nfunc viewDidLoad() {\n  super.viewDidLoad()\n  let titleView = DropdownTitleView()\n  titleView.configure(title: \"Hello world!\", subtitle: \"Is this thing on?\")\n  navigationItem.titleView = titleView\n}\n```\n\n![Example](readme.png)\n\nAdd touch handling like you would any other `UIControl`:\n\n```swift\nfunc viewDidLoad() {\n  super.viewDidLoad()\n  // setup and set titleView\n  titleView.addTarget(\n    self, \n    action: #selector(onTitle), \n    for: .touchUpInside\n  )\n}\n\n@objc func onTitle() {\n  print(\"do something\")\n}\n```\n\n### Configuration\n\n`DropdownTitleView` has several appearance options:\n\n- `titleFont` and `titleColor` - `UIFont` and `UIColor` of the top title label\n- `subtitleFont` and `subtitleColor` - `UIFont` and `UIColor` of the bottom subtitle label\n- `chevronTintColor` - `UIColor` tint of the chevron image\n\nAll of these values are configurable via `UIAppearance` as well!\n\n```swift\nDropdownTitleView.appearance().chevronTintColor = .blue\nDropdownTitleView.appearance().titleColor = .black\nDropdownTitleView.appearance().subtitleColor = .lightGray\nDropdownTitleView.appearance().titleFont = .systemFontOfSize(18)\nDropdownTitleView.appearance().subtitleFont = .systemFontOfSize(13)\n```\n\nYou can also control the features of the view with params in `configure(...)` function:\n\n- `subtitle` - Leave `nil` to remove the subtitle and vertically center the title\n- `chevronEnabled` - Set to `false` to remove the chevron\n- `accessibilityLabel` and `accessibilityHint` - Set Accessibility features on the control\n\n## Acknowledgements\n\n- Created with ❤️ by [Ryan Nystrom](https://twitter.com/_ryannystrom)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgithawkapp%2Fdropdowntitleview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgithawkapp%2Fdropdowntitleview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgithawkapp%2Fdropdowntitleview/lists"}