Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/Azuritul/AZExpandableIconListView
An expandable/collapsible view component written in Swift.
https://github.com/Azuritul/AZExpandableIconListView
accordion collapsible scrollview swift toy
Last synced: 3 months ago
JSON representation
An expandable/collapsible view component written in Swift.
- Host: GitHub
- URL: https://github.com/Azuritul/AZExpandableIconListView
- Owner: Azuritul
- License: mit
- Archived: true
- Created: 2016-01-28T10:58:43.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2019-10-09T07:22:34.000Z (about 5 years ago)
- Last Synced: 2024-08-04T22:42:33.719Z (3 months ago)
- Topics: accordion, collapsible, scrollview, swift, toy
- Language: Swift
- Homepage:
- Size: 234 KB
- Stars: 289
- Watchers: 8
- Forks: 35
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-ios-star - AZExpandableIconListView - An expandable/collapsible view component written in Swift. (UI / Font)
- awesome-ios - AZExpandableIconListView - An expandable/collapsible view component written in Swift. (UI / Font)
README
# AZExpandableIconListView
[![Build Status](https://app.bitrise.io/app/fe6be37387be0f5a/status.svg?token=vylVe85CKuVfX5Wuzs_n0A&branch=config/ci)](https://app.bitrise.io/app/fe6be37387be0f5a)
[![Version](https://img.shields.io/cocoapods/v/AZExpandableIconListView.svg?style=flat)](http://cocoapods.org/pods/AZExpandableIconListView)
[![License](https://img.shields.io/cocoapods/l/AZExpandableIconListView.svg?style=flat)](http://cocoapods.org/pods/AZExpandableIconListView)
[![Platform](https://img.shields.io/cocoapods/p/AZExpandableIconListView.svg?style=flat)](http://cocoapods.org/pods/AZExpandableIconListView)
[![Language](https://img.shields.io/badge/swift-5.0-orange.svg)](http://swift.org)An expandable/collapsible UIView that holds an array of UIImageView. Something like accordion. An interesting practice with auto layout and animation.
## Screenshots
![expandable](https://cloud.githubusercontent.com/assets/879197/12738681/49bc442c-c9a6-11e5-976e-68650cbe4af2.gif)## Requirements
- iOS 11 or above
- Xcode 11 or above
- Swift 5## Demo Project
To run the example project, clone the repo with `git clone https://github.com/Azuritul/AZExpandableIconListView.git`, and run `pod install` from the Example directory first.## Usage
Initialize the view with frame and an array of images, for example:
```Swift
let expandable = AZExpandableIconListView(frame: CGRectMake(4, 30, UIScreen.mainScreen().bounds.size.width - 20, 70), images: [image1, image2, image3])
view.addSubview(expandable)
```
Notice that the width and height of the icons in the view would always be 80% of the containing view's height.### Configurable options
Currently AZExpandableIconListView can be customized with the following properties. More will come in the future.- `imageSpacing` The space between icons. Default is 4.
- `onExpanded` The method to be called when the menu is expanded. Default is null.
- `onCollapsed` The method to be called when the menu is collapsed. Default is null.## Installation
AZExpandableIconListView is available through [CocoaPods](http://cocoapods.org). To install
it, simply add the following line to your Podfile:```ruby
use_frameworks!
pod 'AZExpandableIconListView'
```
## Version
- 1.0.1
- Fix lint warning
- 1.0.0
- Updated for Swift 5
- 0.2.0
- Updated for Swift 3
- 0.1.1
- Updated README
- 0.1.0
- Initial version## Credit
- Avatar icon used in README's screenshot is [Designed by Skydesign - Freepik.com](http://www.freepik.com/free-photos-vectors/people)
## Author
Chris Wu (Azuritul), [email protected]
## License
AZExpandableIconListView is available under the MIT license. See the LICENSE file for more info.