ThreeLevelAccordian alternatives and similar libraries
Based on the "Table View / Collection View" category.
Alternatively, view ThreeLevelAccordian alternatives based on common mentions on social networks and blogs.
-
SwipeCellKit
Swipeable UITableViewCell/UICollectionViewCell based on the stock Mail.app, implemented in Swift. -
MCSwipeTableViewCell
DISCONTINUED. 👆 Convenient UITableViewCell subclass that implements a swippable content to trigger actions (similar to the Mailbox app). -
HGPlaceholders
Nice library to show placeholders and Empty States for any UITableView/UICollectionView in your project -
ReverseExtension
A UITableView extension that enables cell insertion from the bottom of a table view. -
Bohr
DISCONTINUED. Bohr allows you to set up a settings screen for your app with three principles in mind: ease, customization and extensibility. -
CenteredCollectionView
A lightweight UICollectionViewLayout that 'pages' and centers its cells 🎡 written in Swift -
CascadingTableDelegate
A no-nonsense way to write cleaner UITableViewDelegate and UITableViewDataSource in Swift. -
ListPlaceholder
ListPlaceholder is a swift library allows you to easily add facebook style animated loading placeholder to your tableviews or collection views. -
GLTableCollectionView
Netflix and App Store like UITableView with UICollectionView, written in pure Swift 4.2 -
KDDragAndDropCollectionView
This component allows for the transfer of data items between collection views through drag and drop -
DataSources
💾 🔜📱 Type-safe data-driven CollectionView, TableView Framework. (We can also use ASCollectionNode) -
DTTableViewManager
Protocol-oriented UITableView management, powered by generics and associated types. -
TLIndexPathTools
TLIndexPathTools is a small set of classes that can greatly simplify your table and collection views. -
CollapsibleTableSectionViewController
:tada: Swift library to support collapsible sections in a table view. -
RHPreviewCell
I envied so much Spotify iOS app this great playlist preview cell 😍, I decided to create my own one 🌶. Now you can give your users ability to quick check "what content is hidden under your UITableViewCell". Great think is that this Library not requires 3D Touch support from user device💥. -
SquareMosaicLayout
An extandable mosaic UICollectionViewLayout with a focus on extremely flexible customizations :large_orange_diamond: -
HoverConversion
DISCONTINUED. HoverConversion realized vertical paging with UITableView. UIViewController will be paging when reaching top or bottom of UITableView contentOffset. -
GenericDataSource
A generic small reusable components for data source implementation for UITableView/UICollectionView in Swift. -
PJFDataSource
PJFDataSource is a small library that provides a simple, clean architecture for your app to manage its data sources while providing a consistent user interface for common content states (i.e. loading, loaded, empty, and error). -
AZCollectionViewController
Easy way to integrate pagination with dummy views in CollectionView, make Instagram "Discover" within minutes. -
ios-dragable-table-cells
DISCONTINUED. Objective-C library for drag-n-drop of UITableViewCells in a navigation hierarchy of view controllers.
WorkOS - The modern identity platform for B2B SaaS
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of ThreeLevelAccordian or a related project?
README
ThreeLevelAccordian
ThreeLevelAccordian is a three level accordian for IOS. It owes its base code to SwiftyAccordionCells. Most of the design is customisable. It goes till three levels. You can customise the font, color, background color of items, add image to them etc. The innermost items can be multiline too. If an element does not have any child elements, expand icon is not shown against them.
Example
To run the example project, clone the repo, and run pod install
from the Example directory first.
Requirements
ios 8.0+
Installation
ThreeLevelAccordian is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "ThreeLevelAccordian"
Basic Usage
There are three types of cells for three levels of Arcadian:
1) TLAHeaderItem: This is the highest level cell.
2) TLACell: This is the second level cell.
3) TLASubItem: This is the innermost cell.
Setup your tableView whichever way you want before initializing ThreeLevelAccordian. If you wish, you can set the background color and other properties, and they will be retained if you do not override them with options.
Find the basic code below:
import ThreeLevelAccordian
class ViewController: UIViewController, TLADelegate {
@IBOutlet weak var tableView: UITableView!
var cells = [TLACell]()
var delegateController: TLAViewController! //This is very very important
override func viewDidLoad() {
super.viewDidLoad()
//Populating data
cells.append(TLAHeaderItem(value: "Header1", imageURL: "headerImage1"))
cells.append(TLACell(value: "Middle item1", imageURL: "cellImage1"))
cells.append(TLASubItem(value: "Lower item1", imageURL: "subItemImage1"))
cells.append(TLACell(value: "Middle item2", imageURL: "cellImage2"))
cells.append(TLASubItem(value: "Lower item2", imageURL: "subItemImage2"))
cells.append(TLACell(value: "Middle item3", imageURL: "cellImage3"))
cells.append(TLAHeaderItem(value: "Header2", imageURL: "headerImage2"))
cells.append(TLACell(value: "Middle item21", imageURL: "cellImage2"))
cells.append(TLASubItem(value: "Lower item21", imageURL: "subItemImage2"))
cells.append(TLACell(value: "Middle item22"))
//Customisation properties..This part is optional
let options: [TLAOption] = [
.CellBackgroundColor(UIColor.whiteColor()),
.CellColor(textColor),
.CellFont(UIFont(name: "HelveticaNeue-Medium", size: 14.0)!),
.CellHeight(44.0),
.UseSingleValues(true),
.UseAccessoryIcons(true),
.ExpandIcon(UIImage(named: "MyExpandIcon.png")!),
.CollapseIcon(UIImage(named: "MyCollapseIcon.png")!),
]
//Not optional :)
//Specify for cell reuse identifier here
let threeLevelAccordian = ThreeLevelAccordian.init(cells: cells, options: options, reuseIdentifier: "checklistAccordianCell")
threeLevelAccordian.delegate = self
//The next three lines are extremely important
delegateController = threeLevelAccordian.controller
tableView.dataSource = delegateController
tableView.delegate = delegateController
tableView.reloadData()
}
//Delegate function
func didSelectItemAtIndex(index: Int) {
let alertController = UIAlertController(title: "Clicked", message: "Clicked \(index)", preferredStyle: UIAlertControllerStyle.Alert)
alertController.addAction(UIAlertAction(title: "Ok", style: UIAlertActionStyle.Cancel, handler: nil))
self.presentViewController(alertController, animated: true, completion: nil)
}
}
Customisations
You can either specify single customisation values for all cell types through the parameters given below:
1) CellBackgroundColor
2) CellColor: Text color
3) CellHeight
4) CellFont
If you want to apply these values, make sure you mark UseSingleValues to true
You can also provide cell type specific customisations. The names are self explanatory.
For TLAHeaderItem
1) HeaderTextFont
2) HeaderTextColor
3) HeaderCellBackgroundColor
4) HeaderCellHeight
For TLACell
1) ItemTextFont
2) ItemTextColor
3) ItemCellBackgroundColor
4) ItemCellHeight
For TLASubItem
1) SubItemTextFont
2) SubItemTextColor
3) SubItemCellBackgroundColor
4) SubItemCellHeighti
5) IsMultiline: Mark this as true if you are expecting your text to be too big for a single line.
Also, if you want default styling that comes with tables, you can pass options as nil.
There is expand and collapse icons shown on default for appropriate rows (that is, if the row can be expanded or needs to be collapsed). You can turn it off or set your own icons for expand or collapse. Parameters for the same are:
1) UseAccessoryIcons: mark false if you do not want to show expand/collapse icons
2) ExpandIcon
3) CollapseIcon
You can use these options as shown in the Basic Usage section.
Author
Amrata Baghel, [email protected]
License
ThreeLevelAccordian is available under the MIT license. See the LICENSE file for more info.
*Note that all licence references and agreements mentioned in the ThreeLevelAccordian README section above
are relevant to that project's source code only.