{"id":19328220,"url":"https://github.com/jndisrupter/jnhorizontalgroupavatarcollectionview","last_synced_at":"2026-03-05T19:05:41.699Z","repository":{"id":56916317,"uuid":"123002310","full_name":"JNDisrupter/JNHorizontalGroupAvatarCollectionView","owner":"JNDisrupter","description":"Horizontal Group Avatar Collection View","archived":false,"fork":false,"pushed_at":"2019-05-05T17:10:25.000Z","size":1466,"stargazers_count":9,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-15T05:02:12.658Z","etag":null,"topics":["avatar","collectionview","group","horizontal","horizontal-scrolling","swift","user-profile"],"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/JNDisrupter.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-26T17:13:54.000Z","updated_at":"2021-03-31T07:27:19.000Z","dependencies_parsed_at":"2022-08-20T21:20:28.564Z","dependency_job_id":null,"html_url":"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JNDisrupter%2FJNHorizontalGroupAvatarCollectionView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JNDisrupter%2FJNHorizontalGroupAvatarCollectionView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JNDisrupter%2FJNHorizontalGroupAvatarCollectionView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JNDisrupter%2FJNHorizontalGroupAvatarCollectionView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JNDisrupter","download_url":"https://codeload.github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250328155,"owners_count":21412572,"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":["avatar","collectionview","group","horizontal","horizontal-scrolling","swift","user-profile"],"created_at":"2024-11-10T02:21:00.714Z","updated_at":"2026-03-05T19:05:41.645Z","avatar_url":"https://github.com/JNDisrupter.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JNHorizontalGroupAvatarCollectionView\n\n[![Version](https://img.shields.io/cocoapods/v/JNHorizontalGroupAvatarCollectionView.svg?style=flat)](http://cocoapods.org/pods/JNHorizontalGroupAvatarCollectionView)\n[![License](https://img.shields.io/cocoapods/l/JNHorizontalGroupAvatarCollectionView.svg?style=flat)](http://cocoapods.org/pods/JNHorizontalGroupAvatarCollectionView)\n[![Platform](https://img.shields.io/cocoapods/p/JNHorizontalGroupAvatarCollectionView.svg?style=flat)](http://cocoapods.org/pods/JNHorizontalGroupAvatarCollectionView)\n\n**JNHorizontalGroupAvatarCollectionView** is used to show a collection of avatar images with the option to show initials, it shows as much as the phone screen can present with a horizontal scrolling to see more.\n\n## Screenshots\n\u003cimg src=\"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/raw/master/Images/screenshot1.png\" width=\"280\"/\u003e\u003cimg src=\"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/raw/master/Images/screenshot2.png\" width=\"280\"/\u003e\n\u003cimg src=\"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/raw/master/Images/screenshot3.png\" width=\"280\"/\u003e\n\u003cimg src=\"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/raw/master/Images/screenshot4.png\" width=\"280\"/\u003e\n\u003cimg src=\"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/raw/master/Images/screenshot5.png\" width=\"280\"/\u003e\n\u003cimg src=\"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/raw/master/Images/screenshot6.png\" width=\"280\"/\u003e\n\u003cimg src=\"https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/raw/master/Images/screenshot7.png\" width=\"280\"/\u003e\n\n## Example\n\nTo run the example project, clone the repo, and run `pod install` from the Example directory first.\n\n## Requirements\n\n- iOS 9.0+ / macOS 10.10+\n- Xcode 9.0+\n- Swift 4+\n\n## Installation\n\n### CocoaPods\n\n[CocoaPods](http://cocoapods.org) is a dependency manager for Cocoa projects. You can install it with the following command:\n\n```bash\n$ gem install cocoapods\n```\n\nTo integrate JNHorizontalGroupAvatarCollectionView into your Xcode project using CocoaPods, specify it in your `Podfile`:\n\n```ruby\n\nuse_frameworks!\n\ntarget '\u003cYour Target Name\u003e' do\npod 'JNHorizontalGroupAvatarCollectionView'\nend\n```\n\nThen, run the following command:\n\n```bash\n$ pod install\n```\n\n## Usage\n\n#### To add JNHorizontalGroupAvatarCollectionView in interface builder:\n\n1. Put some UIView and change the class to \"JNHorizontalGroupAvatarCollectionView\"\n\n2. Add refrence for it in the view controller.\n\n3. Implement JNHorizontalGroupAvatarCollectionViewDelegate in your view controller and set delegate like the following:\n\n```swift\n\n/**\nNumber of items\n- Returns: The number of items in collection view\n*/\nfunc horizontalGroupAvatarCollectionViewNumberOfItems() -\u003e Int\n\n/**\nData for item at index\n- Parameter index: The item index\n- Returns: The data for the item\n*/\nfunc horizontalGroupAvatarCollectionView(dataForItemAt index: Int) -\u003e [JNGroupAvatar]\n\n/**\nDid clear data\n*/\nfunc horizontalGroupAvatarCollectionViewDidClearData()\n```\n\n4. Implement JNGroupAvatar In your items 'like users' class like the following:\n\n```swift\n\n/**\nGet display name which will be used for the initials.\n- Returns: The display name for the avatar\n*/\nfunc getGroupAvatarDisplayName() -\u003e String\n\n/**\nGet Avatar image url which will be used as avatar url\n- Returns: The image url\n*/\nfunc getGroupAvatarImageUrl() -\u003e String\n\n/**\nGet Avatar image which will be used as avatar\n- Returns: The image\n*/\nfunc getGroupAvatarImage() -\u003e UIImage\n```\n\n* cellPadding : The padding between each avatars image.\n* avatars : Array fo JNGroupAvatar which will be used to draw .\n* imagesLayoutDirection : The image layout direction to use (right to left or left to right).\n* avatarsMargin : The margin between avatars (separator with or height).\n* separatorColor : The separator color to use.\n* placeHolderImage : The placeholder to use if the image failed to load.\n* showInitails : Show initials if the image failed to load or not, if false then set placeholder image.\n* initialsFont : The font to use for the initials.\n* initialTextColor : The text color to use for the initials.\n\n\u003e The libarary is dependant on [JNGroupAvatarImageView](https://github.com/JNDisrupter/JNGroupAvatarImageView), check it for more info.\n\n\n## Author\n\nJayel Zaghmoutt, Mohammad Nabulsi \u0026 Ali Hamad\n\n## License\n\nJNHorizontalGroupAvatarCollectionView is available under the MIT license. See the [LICENSE](https://github.com/JNDisrupter/JNHorizontalGroupAvatarCollectionView/blob/master/LICENSE) file for more info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjndisrupter%2Fjnhorizontalgroupavatarcollectionview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjndisrupter%2Fjnhorizontalgroupavatarcollectionview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjndisrupter%2Fjnhorizontalgroupavatarcollectionview/lists"}