Попробуйте отследить индекс для нажатой кнопки с помощью переменной.И используйте переменную в tableView (_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell, чтобы обновить видимость кнопки.Единственное, что вам нужно сделать в didSelectRowAt, это присвоить значение индекса переменной и перезагрузить табличное представление
var selectedIndex: Int?
....
func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
selectedIndex = indexPath.row
tableView.reloadData()
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
.....
cell.compose.isHidden = indexPath.row != selectedIndex
.....
return cell
}