File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -338,8 +338,15 @@ extension HomeViewController: UITableViewDataSource {
338338
339339 func tableView( _ tableView: UITableView , cellForRowAt indexPath: IndexPath ) -> UITableViewCell {
340340 var cell : UITableViewCell !
341-
342- if sections [ indexPath. section] . type == . seeAllStops {
341+
342+ if sections [ indexPath. section] . type == . favorites &&
343+ sections [ indexPath. section] . items. first? . name == Constants . General. firstFavorite
344+ {
345+ cell = tableView. dequeueReusableCell ( withIdentifier: Constants . Cells. placeIdentifier) as? PlaceTableViewCell
346+ cell. textLabel? . text = Constants . General. firstFavorite
347+ cell. detailTextLabel? . text = Constants . General. tapHere
348+ ( cell as? PlaceTableViewCell ) ? . iconColor = Colors . tcatBlue
349+ } else if sections [ indexPath. section] . type == . seeAllStops {
343350 cell = tableView. dequeueReusableCell ( withIdentifier: Constants . Cells. seeAllStopsIdentifier)
344351 cell. textLabel? . text = Constants . General. seeAllStops
345352 cell. imageView? . image = #imageLiteral( resourceName: " list " )
Original file line number Diff line number Diff line change @@ -195,6 +195,7 @@ struct Constants {
195195 /// General phrases used throughout the app
196196 struct General {
197197 static let firstFavorite = " Add Your First Favorite! "
198+ static let tapHere = " Tap Here "
198199 static let searchPlaceholder = " Where to? "
199200 static let favoritesPlaceholder = " Search any destination "
200201 static let fromSearchBarPlaceholder = " Choose starting point... "
You can’t perform that action at this time.
0 commit comments