{"id":13696558,"url":"https://github.com/liufengting/FTPopOverMenu","last_synced_at":"2025-05-03T17:31:36.729Z","repository":{"id":46101028,"uuid":"55603800","full_name":"liufengting/FTPopOverMenu","owner":"liufengting","description":"FTPopOverMenu is a pop over menu for iOS which is maybe the easiest one to use. Supports both portrait and landscape. It can show from any UIView, any UIBarButtonItem and any CGRect.","archived":false,"fork":false,"pushed_at":"2023-11-10T05:49:56.000Z","size":3478,"stargazers_count":1044,"open_issues_count":16,"forks_count":171,"subscribers_count":30,"default_branch":"master","last_synced_at":"2024-11-07T04:42:17.091Z","etag":null,"topics":["button","cocoapods","menu","navigation-items","pop","popover"],"latest_commit_sha":null,"homepage":"","language":"Objective-C","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/liufengting.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,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2016-04-06T12:27:16.000Z","updated_at":"2024-10-25T02:20:12.000Z","dependencies_parsed_at":"2024-04-13T00:41:09.510Z","dependency_job_id":"2b5d4f19-e2f9-4600-bbc9-4624bac25876","html_url":"https://github.com/liufengting/FTPopOverMenu","commit_stats":{"total_commits":188,"total_committers":9,"mean_commits":20.88888888888889,"dds":0.09042553191489366,"last_synced_commit":"89392a4c084b6a188ba159922d22dac6a1f1cfc1"},"previous_names":[],"tags_count":39,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liufengting%2FFTPopOverMenu","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liufengting%2FFTPopOverMenu/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liufengting%2FFTPopOverMenu/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liufengting%2FFTPopOverMenu/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/liufengting","download_url":"https://codeload.github.com/liufengting/FTPopOverMenu/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223786721,"owners_count":17202590,"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":["button","cocoapods","menu","navigation-items","pop","popover"],"created_at":"2024-08-02T18:00:42.530Z","updated_at":"2024-11-13T00:30:39.213Z","avatar_url":"https://github.com/liufengting.png","language":"Objective-C","funding_links":[],"categories":["UI Components"],"sub_categories":[],"readme":"![FTPopOverMenu](https://github.com/liufengting/FTResourceRepo/blob/master/Resource/FTPopOverMenu_logo/logotype_1280.png?raw=true)\n\n# FTPopOverMenu\n\n[![Twitter](https://img.shields.io/badge/twitter-@liufengting-blue.svg?style=flat)](http://twitter.com/liufengting) \n[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/liufengting/FTPopOverMenu/master/LICENSE)\n[![Version](https://img.shields.io/cocoapods/v/FTPopOverMenu.svg?style=flat)](http://cocoapods.org/pods/FTPopOverMenu)\n[![Codebeat badge](https://codebeat.co/badges/763991fb-8307-4683-8b19-6c8aba9f1683)](https://codebeat.co/projects/github-com-liufengting-ftpopovermenu)\n[![Download](https://img.shields.io/cocoapods/dt/FTPopOverMenu.svg?maxAge=2592000)](http://cocoapods.org/pods/FTPopOverMenu)\n[![CocoaPods](https://img.shields.io/cocoapods/at/FTPopOverMenu.svg?maxAge=2592000)](http://cocoapods.org/pods/FTPopOverMenu)\n[![CocoaPods](https://img.shields.io/cocoapods/metrics/doc-percent/FTPopOverMenu.svg?maxAge=2592000)](http://cocoapods.org/pods/FTPopOverMenu)\n[![CI Status](http://img.shields.io/travis/liufengting/FTPopOverMenu.svg?style=flat)](https://travis-ci.org/liufengting/FTPopOverMenu)\n[![GitHub stars](https://img.shields.io/github/stars/liufengting/FTPopOverMenu.svg)](https://github.com/liufengting/FTPopOverMenu/stargazers)\n[![Gitter](https://badges.gitter.im/liufengting/FTPopOverMenu.svg)](https://gitter.im/liufengting/FTPopOverMenu?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge)\n\n`FTPopOverMenu` is a pop over menu for `iOS` which is maybe the easiest one to use, supports both `portrait` and `landscape`. It can show from any `UIView`, any `UIBarButtonItem` and any `CGRect`. Simplest APIs, enable you to change the style in one line of code.\n\n\n### menu array supports following context:\n\n* image name (NSString, only main bundle),\n* image (UIImage),\n* image remote URL string (NSString),\n* image remote URL (NSURL),\n* model (FTPopOverMenuModel, select state support)\n\n### ⚠️ Big API Change from `1.3.6` to `2.0.0` (See [CHANGELOG](https://github.com/liufengting/FTPopOverMenu/blob/master/CHANGELOG.md) for more info)\n\n* supports separated configuration. \n* change 'tintColor' to 'backgroundColor'\n\n# About Swift Version\n\n`FTPopOverMenu_Swift` is now published. [Take a look at it now](https://github.com/liufengting/FTPopOverMenu_Swift). The swift version has same APIs with this OC version.\n\n# ScreenShots\n\n![screenshots](https://raw.githubusercontent.com/liufengting/FTResourceRepo/master/Resource/FTPopOverMenu/screenshots.gif)\n\n## Recently UrbanHooker added round arrow support, I changed a little bit.\n\n![screenshots](https://raw.githubusercontent.com/liufengting/FTResourceRepo/master/Resource/FTPopOverMenu/FTPopOverMenuRoundArrow.png)\n\n# Installation\n\n## Manually\n\n* clone this repo.\n* Simply drop the '/FTPopOverMenu' folder into your project.\n* import 'FTPopOverMenu.h'\n\n## CocoaPods\n`FTPopOverMenu` is available through [CocoaPods](http://cocoapods.org). To install it, simply add the following line to your Podfile:\n\n```ruby\npod 'FTPopOverMenu'\n```\n\n# Usage\n\n## Customize\n\nDo any of the following settings to set the style (Only set the ones you want to change) before showing.\n\n```objective-c\n    FTPopOverMenuConfiguration *configuration = [FTPopOverMenuConfiguration defaultConfiguration];\n    configuration.menuRowHeight = ...\n    configuration.menuWidth = ...\n    configuration.textColor = ...\n    configuration.textFont = ...\n    configuration.tintColor = ...\n    configuration.borderColor = ...\n    configuration.borderWidth = ...\n    configuration.textAlignment = ...\n    configuration.ignoreImageOriginalColor = ...;// set 'ignoreImageOriginalColor' to YES, images color will be same as textColor\n    configuration.allowRoundedArrow = ...// Default is 'NO', if sets to 'YES', the arrow will be drawn with round corner.\n    configuration.separatorColor = ...\n    configuration.shadowColor = ... // Default is black\n    configuration.shadowOpacity = ... // Default is 0 - choose anything between 0 to 1 to show actual shadow, e.g. 0.2\n    configuration.shadowRadius = ... // Default is 5\n    configuration.shadowOffsetX = ...\n    configuration.shadowOffsetY = ...\n```\n\n\n## ~~setTintColor, default is gray color.~~ deprecated after 1.2.0\n\n```objective-c\n    [FTPopOverMenu setTintColor:[UIColor redColor]];\n```\n## ~~setTextColor, default is white color.~~ deprecated after 1.2.0\n\n```objective-c\n    [FTPopOverMenu setTextColor:[UIColor blackColor]];\n```\n\n## ~~setPreferedWidth, default is 120, should not be less than 50.~~ deprecated after 1.2.0\n\n```objective-c\n    [FTPopOverMenu setPreferedWidth:200];\n```\n\n## From SenderView, Menu Without Images.\n \n```objective-c\n    [FTPopOverMenu showForSender:sender\n                        withMenu:@[@\"MenuOne\",@\"MenuTwo\",@\"MenuThr\"]\n                       doneBlock:^(NSInteger selectedIndex) {\n                           \n                       } dismissBlock:^{\n                          \n                       }];\n```\n\n## From SenderView, Menu With Images.\n \n```objective-c\n    [FTPopOverMenu showForSender:sender\n                        withMenu:@[@\"MenuOne\",@\"MenuTwo\",@\"MenuThr\"]\n                  imageNameArray:@[@\"setting_icon\",@\"setting_icon\",@\"setting_icon\"]\n                       doneBlock:^(NSInteger selectedIndex) {\n                           \n                       } dismissBlock:^{\n                          \n                       }];\n```\n\n## From SenderView, Menu With Images, custom configuration.\n \n```objective-c\n    [FTPopOverMenu showForSender:sender\n                        withMenu:@[@\"MenuOne\",@\"MenuTwo\",@\"MenuThr\"]\n                  imageNameArray:@[@\"setting_icon\",@\"setting_icon\",@\"setting_icon\"]\n                   configuration:customConfiguration\n                       doneBlock:^(NSInteger selectedIndex) {\n                           \n                       } dismissBlock:^{\n                          \n                       }];\n```\n\n## From SenderFrame/NavigationItem, Menu Without Images.\n \n```objective-c\n    [FTPopOverMenu showFromSenderFrame:CGRectMake(self.view.frame.size.width - 40, 20, 40, 40)\n                              withMenu:@[@\"123\",@\"234\",@\"345\"]\n                             doneBlock:^(NSInteger selectedIndex) {\n                                 \n                             } dismissBlock:^{\n                                 \n                             }];\n```\n\n## From SenderFrame/NavigationItem, Menu With Images.\n \n```objective-c\n    [FTPopOverMenu showFromSenderFrame:CGRectMake(self.view.frame.size.width - 40, 20, 40, 40)\n                              withMenu:@[@\"123\",@\"234\",@\"345\"]\n                        imageNameArray:@[@\"setting_icon\",@\"setting_icon\",@\"setting_icon\"]\n                             doneBlock:^(NSInteger selectedIndex) {\n                                 \n                             } dismissBlock:^{\n                                 \n                             }];\n```\n\n## From SenderFrame/NavigationItem, Menu With Images, custom configuration.\n \n```objective-c\n    [FTPopOverMenu showFromSenderFrame:CGRectMake(self.view.frame.size.width - 40, 20, 40, 40)\n                              withMenu:@[@\"123\",@\"234\",@\"345\"]\n                        imageNameArray:@[@\"setting_icon\",@\"setting_icon\",@\"setting_icon\"]\n\t                     configuration:customConfiguration\n                             doneBlock:^(NSInteger selectedIndex) {\n                                 \n                             } dismissBlock:^{\n                                 \n                             }];\n```\n\n## From barButtonItems .\n\n- First: add action with event to you barButtonItems \n\n```objective-c\n    [self.navigationItem setRightBarButtonItem:[[UIBarButtonItem alloc] initWithTitle:@\"Edit\" style:UIBarButtonItemStyleDone target:self action:@selector(onNavButtonTapped:event:)]];\n```\n\n- Second: implement the action, also supports custom configuration.\n\n```objective-c\n-(void)onNavButtonTapped:(UIBarButtonItem *)sender event:(UIEvent *)event\n{\n\n    [FTPopOverMenu showFromEvent:event\n                        withMenu:@[@\"123\",@\"234\",@\"345\"]\n                  imageNameArray:@[@\"setting_icon\",@\"setting_icon\",@\"setting_icon\"]\n                  configuration:customConfiguration\n                       doneBlock:^(NSInteger selectedIndex) {\n                           \n                       } dismissBlock:^{\n                           \n                       }];\n}\n```\n\n# CHANGELOG\n\n[CHANGELOG](https://github.com/liufengting/FTPopOverMenu/blob/master/CHANGELOG.md)\n\n# More\n\n* Logo Designed by @Tobaloidee\n* Images in the demo from [https://www.iconfinder.com/iconsets/pokemon-go](https://www.iconfinder.com/iconsets/pokemon-go).\n* If you like it, or maybe wanna use it in your own projects, please give me a `star`.\n* Looking for another way of doing this? Take a look at my another [FTPopMenu at here](https://github.com/liufengting/FTPopMenu).  It was another way of showing pop over menus, which is wrapped from `UIPopoverViewController`, and more genetic and more good-looking. Feel free to try it.\n \n\n\u003cimg src=\"https://raw.githubusercontent.com/liufengting/FTPopMenu/master/ScreenShots/ScreenShots2.png\" width=\"300\"/\u003e\n\n\n# License\n\n`FTPopOverMenu` is available under the `MIT` license. See the `LICENSE` file for more info.\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliufengting%2FFTPopOverMenu","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliufengting%2FFTPopOverMenu","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliufengting%2FFTPopOverMenu/lists"}