   static let separatorHeight: CGFloat       =  1
 }
 
+/// Displays a list of items that the user can toggle on and off.
+///
+/// Call the `configure` method to set the available items, then attach to `rx_pickModes` to listen to changes
+/// of the user tapping on items.
 public class TKUIModePicker<Item>: UIView where Item: TKUIModePickerItem {
   
   private let disposeBag = DisposeBag()

import RxSwift
import TripKit

public protocol TKUIModePickerItem: Hashable {
  var image: TKImage? { get }
  var imageTextRepresentation: String { get }
  var imageURL: URL? { get }
  var imageURLIsTemplate: Bool { get }
  var imageURLIsBranding: Bool { get }
}


  private var visibleModes: [Item] = []
  
  private var modeIsBranded: [Item: Bool] = [:]

  /// Configures the currently visible items
  ///
  /// - Note: you can call `configure` multiple times with different sets of items. The mode picker will keep track
  ///     of which items were previously selected (or not) and maintains that information even if the items are
  ///     temporarily removed from the `configure` method's `modes`
  ///
  /// - Parameters:
  ///   - modes: These are all the available/visible modes
  ///   - currentlyEnabled:  Optional handler to check if an item should be enabled; by default all are enabled
  public func configure(all modes: [Item], currentlyEnabled: (Item) -> Bool = { _ in true }) {

    // Need to set this first, as updating modes will trigger the observable
