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

IBX-8418: Added drafts deletion warning to trash modal #1321

Open
wants to merge 11 commits into
base: 4.6
Choose a base branch
from
5 changes: 5 additions & 0 deletions src/bundle/Resources/translations/messages.en.xliff
Original file line number Diff line number Diff line change
Expand Up @@ -688,6 +688,11 @@
<target state="new">Are you sure you want to send this Content item to Trash?</target>
<note>key: trash.modal.send_to_trash.message</note>
</trans-unit>
<trans-unit id="b107e8277d2dda6c41872a6478d99abbe9b46dc0" resname="trash.modal.send_to_trash_draft_warning.message">
<source>Sending this content item to Trash will also delete all drafts of content items that haven’t been published yet, and belong to the trashed subtree.</source>
<target state="new">Sending this content item to Trash will also delete all drafts of content items that haven’t been published yet, and belong to the trashed subtree.</target>
<note>key: trash.modal.send_to_trash_draft_warning.message</note>
</trans-unit>
<trans-unit id="bd97a738137e75de44544db1104bab3a46222791" resname="trash_asset.modal.message_body">
<source>If you wish to delete these assets too, first make sure they are not used by other content. To check, go to the asset preview and look at its content Relations in the Relations tab.</source>
<target state="new">If you wish to delete these assets too, first make sure they are not used by other content. To check, go to the asset preview and look at its content Relations in the Relations tab.</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@
{% endblock %}
{% block body_content %}
{{ 'trash.modal.send_to_trash.message'|trans|desc('Are you sure you want to send this Content item to Trash?') }}
<div class="ibexa-modal__trash-option">
<p class="ibexa-modal__option-label ibexa-label form-label required">
Copy link
Contributor

Choose a reason for hiding this comment

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

label with "*" as an explanation is probably not the best UX.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@dew326 Don't we have the same for Conflicts with relations and Sub-items warnings?

Copy link
Contributor

Choose a reason for hiding this comment

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

Not in this styling. The explanation is bigger and not gray.

Copy link
Contributor Author

@barw4 barw4 Aug 12, 2024

Choose a reason for hiding this comment

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

Ok, should I go with a simple paragraph then? Or any other example in which any particular html elements/classes should be used?

Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe we should add a new "trash_option" for example: "Drafts" and there put this explanation.
This is probably for @NataliaBecla and @juskora.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hi @NataliaBecla, can we get your feedback on this?

Choose a reason for hiding this comment

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

@barw4 It seems there was a misunderstanding, as I thought we had resolved everything during the meeting. I suggest we go with @dew326 suggestion to use "Draft" as the title and format the sentence "sending this content item..." in regular font as shown below.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

okay, will do, thank you

Choose a reason for hiding this comment

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

Great @barw4 👌👍 Looks good

{{ 'trash.modal.send_to_trash_draft_warning.message'|trans|desc('Sending this content item to Trash will also delete all drafts of content items that haven’t been published yet, and belong to the trashed subtree.') }}
</p>
</div>

{% for option in form.trash_options %}
<div class="ibexa-modal__trash-option">
Expand Down
Loading