Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace checkbox with umb-checkbox in listview publish and unpublish overlay #6544

Merged

Conversation

bjarnef
Copy link
Contributor

@bjarnef bjarnef commented Oct 1, 2019

Prerequisites

  • I have added steps to test this contribution in the description below

Description

I noticed when a document type vary by culture and there is multiple languages configurated, the listview publish and unpublish used traditional checkboxes, while the general unpublish and publish with descendants overlays use umb-checkbox component.

Furthermore the unpublish button in listview overlay is warning style as the general unpublish overlay.

image

image

I am not sure if it is a bug that it has a condition ng-if="vm.languages.length > 1" in "listviewpublish" while it has ng-if="vm.languages.length > 0 in "listviewunpublish"?

https://github.com/umbraco/Umbraco-CMS/blob/v8/dev/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/overlays/listviewpublish.html#L7

https://github.com/umbraco/Umbraco-CMS/blob/v8/dev/src/Umbraco.Web.UI.Client/src/views/propertyeditors/listview/overlays/listviewunpublish.html#L9

@bjarnef
Copy link
Contributor Author

bjarnef commented Oct 1, 2019

With only a single language there is this difference between "listviewpublish" and "listviewunpublish" regarding the vm.languages.length > 0 vs vm.languages.length > 1:

image

image

Maybe both of these should show the single language, but the checkbox could be disabled and the label could have a disabled style using e.g. muted class.

Or should we only show languages in publish/unpublish overlays when more than a single language is configurated? They should however be consistent in the way they show or not show the languages.

@nul800sebastiaan
Copy link
Member

Looks nice, thanks Bjarne, we'll have a look soon!

@nul800sebastiaan
Copy link
Member

Good point, it was always supposed to only show the checkboxes if there are multiple choices, so I updated listviewunpublish.html to check for vm.languages.length > 1 instead of 0 👍

@nul800sebastiaan nul800sebastiaan merged commit d7b25fc into umbraco:v8/dev Oct 14, 2019
@nul800sebastiaan
Copy link
Member

Great update, thanks @bjarnef! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants