User tests: Successful: Unsuccessful:
Many list views in backend can be empty. As for example articles, menu items, contacts ....
Nevertheless there is always a full set of action buttons: publish, unpublish, batch, trash. But none of these has a function as long as the list is empty.
So only the one button "new" is needed, all the other buttons are useless.
This patch shows for the menu-items view how it could be made easier in a very simple way.
It is also a step towards accessibility as there are less elements to be tabbed or read by a screen reader.
This could be made for many list views: articles, contacts, user notes and so on if this is acepted.
Have a look on a empty Menu items list
yes
Status | New | ⇒ | Pending |
Category | ⇒ | Administration com_menus |
Labels |
Added:
?
|
Title |
|
We need to extend this for all components for sure
Tested here ok. Waiting for the remove of whitespace tabs
@Quy a question about this, do you think ToolbarHelper class can have a param in each method (where it makes sense to check if there are elements for actions like publish, delete etc) for check this? In this way when you do ToolbarHelper::publish(....) he will check first if the actual view has items where these action have sense.
please dont misunderstand me - i am a massive fan of progressive disclosure of buttons and I have tried with others to add this to joomla for 4 years. But in the new proposed toolbar there will just be a new and an actions button so I dont believe it is needed anymore
@brianteeman really? where I can see this you said?
quick example joomla/40-backend-template#422
Thank you @brianteeman . With a fast look, still relevant this PR IMO, is a button and a dropdown less
Now as I have seen the new Screen, I think that also Elements like Search tools can be hidden on a empty list, because they cannot give a result. This could be made with the same simple condition.
I think that also Elements like Search tools can be hidden on a empty list, because they cannot give a result
You can't hide search tools on an empty screen. If you search/filter for something that yields no search results, you'd hide the search bar and make it impossible to clear the filters without logging out. This bug already exists in core (in fact we fixed one of those with 3.8.8).
Rebuild
is an independent action from the other buttons. Should it be hidden too?
So it seems that it is better to ask for each or element if it makes sense. If there are no items at all, it is not necessary. So @carlitorweb has already mentioned the ToolbarHelper Class, which could be used for this purpose.
@Quy a question about this, do you think ToolbarHelper class can have a param in each method (where it makes sense to check if there are elements for actions like publish, delete etc) for check this? In this way when you do ToolbarHelper::publish(....) he will check first if the actual view has items where these action have sense.
Closed as there are other solutions
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2018-11-28 23:26:43 |
Closed_By | ⇒ | chmst |
With the proposed new UI and a combined actions button is this even needed