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

Move version "Clean" button to details page #5706

Merged
merged 2 commits into from
May 30, 2019
Merged

Conversation

humitos
Copy link
Member

@humitos humitos commented May 17, 2019

Instead of showing the "Clean" button next to a version in the "Inactive Versions" listing, this button is moved to the detail page with an explanation about what it does.

Changed from,

Screenshot_2019-05-17_13-10-27

to,

Screenshot_2019-05-17_13-18-35

This change is made because we found that multiple buttons in a row breaks in other languages when translated (because of margin/padding). Also, this button is not shown at all in the corporate site and it should be --but we don't want to show it in the listing.

@humitos humitos requested a review from a team May 17, 2019 11:16
Instead of showing the "Clean" button next to a version in the
listing, this button is moved to the detail page with an explanation
about what it does.
@humitos humitos force-pushed the humitos/move-clean-button branch from 1a8ea0d to 9d508a0 Compare May 17, 2019 11:18
@humitos
Copy link
Member Author

humitos commented May 17, 2019

As a side note, I think that ending up with a active=False and built=True version may not possible anymore after #5600 since it was the only place where those fields were not updated together.

Now, when we update a version from the dashboard we do these all together:

  1. mark is as active=False
  2. remove the documentation's file
  3. mark it as built=False

On the other hand, our new automation rules and APIv3 version edit probably does not behaves in the same way. This is outside the scope of this PR, but may worth to consider to unify the behavior when the same action is performed by the user.

Copy link
Contributor

@agjohnson agjohnson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change looks great, I think it does improve the UX as Clean is not a primary function for version objects.

Noted a translation change to clean up, but looks good otherwise 👍

{% if not version.active and version.built %}
<p class="empty">
{% url "project_version_delete_html" project.slug version.slug as version_delete_url %}
{% blocktrans %}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use trimmed on the blocktrans call to improve the text whitespace handling in gettext

@humitos humitos merged commit 6a84ae6 into master May 30, 2019
@delete-merged-branch delete-merged-branch bot deleted the humitos/move-clean-button branch May 30, 2019 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants