Skip to content

Commit

Permalink
Merge pull request #1768 from nextcloud/banned-placeholder-view
Browse files Browse the repository at this point in the history
Show placeholder view when there are no banned users
  • Loading branch information
SystemKeeper committed Aug 21, 2024
2 parents 02cac77 + aa8da7a commit 40828ee
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 3 additions & 1 deletion NextcloudTalk/BannedActorTableViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,9 @@
self.tableView.register(UINib(nibName: bannedActorCellIdentifier, bundle: nil), forCellReuseIdentifier: bannedActorCellIdentifier)
self.tableView.backgroundView = backgroundView

// We only want the loadingView, so always hide the placeholder
self.backgroundView.placeholderView.isHidden = true
self.backgroundView.placeholderTextView.text = NSLocalizedString("No banned users or guests", comment: "")
self.backgroundView.setImage(UIImage(systemName: "person.badge.minus"))
self.backgroundView.loadingView.startAnimating()

self.modifyingViewIndicator.color = NCAppBranding.themeTextColor()
Expand All @@ -62,6 +63,7 @@

self.backgroundView.loadingView.stopAnimating()
self.backgroundView.loadingView.isHidden = true
self.backgroundView.placeholderView.isHidden = !self.bannedActors.isEmpty

self.tableView.reloadData()
self.hideActivityIndicator()
Expand Down
3 changes: 3 additions & 0 deletions NextcloudTalk/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -1174,6 +1174,9 @@
/* No comment provided by engineer. */
"No actions available" = "No actions available";

/* No comment provided by engineer. */
"No banned users or guests" = "No banned users or guests";

/* No comment provided by engineer. */
"No description provided" = "No description provided";

Expand Down

0 comments on commit 40828ee

Please sign in to comment.