Problem/Motivation

The save button on the Image style form is labeled "Update style". In general, buttons to save changes should be labeled "Save". See https://www.drupal.org/docs/develop/user-interface-standards/interface-text

"Update style" is confusing here because (even though "Update" is used rarely in the UI) update in other cases refers to updating what is visible on the page without actually saving anything.
Screenshot showing a button with the wording Update stye

Proposed resolution

Rename the label of the button from "Update style" to "Save".

Remaining tasks

  • Change the label wording
  • Update the tests

User interface changes

This is a UI text change, but it's changing it to string that that will already be translated anyway.

API changes

None.

Data model changes

None.

Comments

ifrik created an issue. See original summary.

ifrik’s picture

Status: Needs work » Needs review
StatusFileSize
new17.24 KB

Changed the wording and the tests.

ifrik’s picture

StatusFileSize
new2.71 KB

Patch and screenshot

artusamak’s picture

This looks good to me!

artusamak’s picture

Status: Needs review » Reviewed & tested by the community

Let's be brave and RTBC that. :)

ifrik’s picture

Assigned: ifrik » Unassigned
Status: Reviewed & tested by the community » Needs review
ifrik’s picture

Status: Needs review » Reviewed & tested by the community

The status change wasn't intended.

claudiu.cristea’s picture

Status: Reviewed & tested by the community » Needs review
Issue tags: +Needs usability review

This needs usability review.

gábor hojtsy’s picture

We've been applying Save as a consistent thing in most places. This would be nice to follow along. Two random examples:

gábor hojtsy’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: -Needs usability review

Status: Reviewed & tested by the community » Needs work

The last submitted patch, 3: 2983548-save-image-style-button-02.patch, failed testing. View results

andypost’s picture

Status: Needs work » Needs review
StatusFileSize
new745 bytes
new2.84 KB

Patch with method removal

+++ b/core/modules/image/src/Form/ImageStyleEditForm.php
@@ -262,7 +262,7 @@ public function save(array $form, FormStateInterface $form_state) {
-    $actions['submit']['#value'] = $this->t('Update style');
+    $actions['submit']['#value'] = $this->t('Save');

Better to remove this method at all because "Save" is default value in http://cgit.drupalcode.org/drupal/tree/core/lib/Drupal/Core/Entity/Entit...

artusamak’s picture

Issue tags: +Novice

Tagging as novice issue if ifrik doesn't have time to take care of it.

ifrik’s picture

Status: Needs review » Reviewed & tested by the community

Thanks,
with regards to php I'm a novice anyway :-)

The patch now applies with the submit button using the default wording "Save".

gábor hojtsy’s picture

Adjusting credits.

gábor hojtsy’s picture

Status: Reviewed & tested by the community » Fixed

Committed b8c4f6e and pushed to 8.6.x. Thanks!

  • Gábor Hojtsy committed b8c4f6e on 8.6.x
    Issue #2983648 by ifrik, andypost, Gábor Hojtsy, Artusamak: Reword the...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.