     }
   }
 
-  func scrollViewWillEndDragging(_ scrollView: UIScrollView,
-                                          withVelocity velocity: CGPoint,
-                                          targetContentOffset: UnsafeMutablePointer<CGPoint>) {
+  func scrollViewWillEndDragging(
+    _ scrollView: UIScrollView,
+    withVelocity velocity: CGPoint,
+    targetContentOffset: UnsafeMutablePointer<CGPoint>
+  ) {
     let headerView = headerViewController.headerView
     if scrollView == headerView.trackingScrollView {
-      headerView.trackingScrollWillEndDragging(withVelocity: velocity,
-                                               targetContentOffset: targetContentOffset)
+      headerView.trackingScrollWillEndDragging(
+        withVelocity: velocity,
+        targetContentOffset: targetContentOffset)
     }
   }
 

      tableView.translatesAutoresizingMaskIntoConstraints = false

      let guide = view.safeAreaLayoutGuide
      NSLayoutConstraint.activate([tableView.leftAnchor.constraint(equalTo: guide.leftAnchor),
                                   tableView.rightAnchor.constraint(equalTo: guide.rightAnchor),
                                   tableView.topAnchor.constraint(equalTo: view.topAnchor),
                                   tableView.bottomAnchor.constraint(equalTo: guide.bottomAnchor)])
    } else {
      preiOS11Constraints()
    }

extension MDCDragonsController {
  func collapseCells(at indexPath: IndexPath) {
    let upperCount = cellsBySection[indexPath.section][indexPath.row].node.children.count
    let indexPaths = (indexPath.row + 1..<indexPath.row + 1 + upperCount).map {
      IndexPath(row: $0, section: indexPath.section)
    }
    tableView.deleteRows(at: indexPaths, with: .automatic)
    cellsBySection[indexPath.section].removeSubrange(
      (indexPath.row + 1..<indexPath.row + 1 + upperCount))

  }

  func expandCells(at indexPath: IndexPath) {
    let nodeChildren = cellsBySection[indexPath.section][indexPath.row].node.children
    let upperCount = nodeChildren.count
    let indexPaths = (indexPath.row + 1..<indexPath.row + 1 + upperCount).map {
      IndexPath(row: $0, section: indexPath.section)
    }
    tableView.insertRows(at: indexPaths, with: .automatic)
    cellsBySection[indexPath.section].insert(
      contentsOf: nodeChildren.map { DragonCell(node: $0) },
      at: indexPath.row + 1)
  }
}

extension MDCDragonsController {
  func setUpKeyboardWatcher() {
    NotificationCenter.default.addObserver(
      self, selector: #selector(keyboardWillShow(notification:)),
      name: .MDCKeyboardWatcherKeyboardWillShow, object: nil)
    NotificationCenter.default.addObserver(
      self, selector: #selector(keyboardWillHide(notification:)),
      name: .MDCKeyboardWatcherKeyboardWillHide, object: nil)
    NotificationCenter.default.addObserver(
      self, selector: #selector(keyboardWillChangeFrame(notification:)),
      name: .MDCKeyboardWatcherKeyboardWillChangeFrame, object: nil)
  }

  @objc func keyboardWillShow(notification: NSNotification) {
