Skip to content

FoldingCell

An iOS UI component: table cells that expand and fold open with a paper-card style animation.

Stars
10.2k
Forks
1.1k
Licence
MIT
Language
Swift
Last update
2.5 years ago
Type
Library

No commits in over a year — check for forks or alternatives before adopting.

What it is

FoldingCell is a Swift library for iOS apps that provides a table view cell which unfolds to reveal more content, with an animation inspired by folding paper cards. Developers use it to show a compact summary that opens into a detailed view when tapped. The README describes it as a single file you can drop into a project, or install through a package manager.

  • Show a list of items where each row unfolds to display extra details
  • Add a folding cell with a configurable number of folds to a storyboard-based table view
  • Build an expandable product or event list in an iOS app

Great for

  • iOS developers building list screens with expandable items
  • Developers who want a ready-made folding animation instead of writing their own
  • Teams adding a Material-style expanding card pattern to a table view

Not ideal for

  • Developers targeting Android or the web, since this is an iOS-only Swift library
  • Projects needing a current, actively documented setup, since the README lists Xcode 10.2 and iOS 8.0+ and the code samples use older Swift syntax
  • Anyone wanting a no-code tool, since integration requires writing table view and cell code
Step-by-step guide: how to use FoldingCellInstall, first run, examples, tips and FAQs

How to get it

  1. 1

    Install with a package manager

    You'll need: Xcode 10.2 (per README) · iOS 8.0+ target (per README)

    CocoaPods (Podfile)

    pod 'FoldingCell'

    Swift Package Manager (Package.swift)

    dependencies: [ .package(url: "https://github.com/Ramotion/folding-cell.git", from: "5.0.2") ]
  2. 2

    Run it

    • Add the library with CocoaPods, Swift Package Manager, or by copying FoldingCell.swift into your project.
    • Create a new cell class that inherits from FoldingCell.
    • In your storyboard or nib, add a RotatedView as the foreground view and connect its outlets to foregroundView and foregroundViewTop.
    • Add another view for the content shown when open and connect it to containerView and containerViewTop.
    • In your table view controller, set cell heights for the closed and open states and toggle the cell on row selection.
  3. 3

    Get the most out of it

    • Set itemCount in the storyboard (range 2 or greater, default 2) to control the number of folds
    • Override animationDuration in your cell class to set timing for each fold
    • Create the foreground and container views in code instead of storyboard, using the linked programmatic example from the README
    • Check the README's linked Android version if you need the same effect on another platform

Downloads

Strengths

  • Simple to add: the README says you can drop in one Swift file or use CocoaPods, Carthage, or Swift Package Manager
  • Configurable animation timing per fold through an overridable method
  • MIT licensed and widely starred on GitHub

Trade-offs

  • The README's code samples use outdated Swift syntax and APIs, so they will need adapting to current Xcode and Swift versions
  • The README lists iOS 8.0+ and Xcode 10.2 as requirements, which may be out of date; no newer compatibility is stated
  • The README does not describe testing status beyond a Travis badge, and the last push date is April 2024

How it compares

ProjectStarsTypeLevelUpdatedBest for
folding-cell (this)10.2kLibraryintermediate2.5 years agoiOS developers building list screens with expandable items
animated-tab-bar11.1kLibraryintermediate4.8 years agoiOS developers who want animated tab bar icons without writing the animation logic from scratch
Hero22.5kLibraryintermediate1.8 years agoiOS developers who want custom screen transitions without writing UIKit animation code by hand
Material12kLibraryintermediate4.5 years agoiOS developers who want Material Design-style components without building them from scratch
NVActivityIndicatorView10.7kLibrarybeginner8 months agoiOS developers who want a ready-made loading indicator with many styles
framework718.8kFrameworkintermediate6 days agoDevelopers who already know HTML, CSS and JavaScript and want to build mobile-style apps

Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.