I would like to suggest 2 improvements to the file diff comparison.

1) It would be nice to be able to open the file by clicking on it so that you can compare the difference more easily.

2) It would be nice to be able to include the file size in the comparison so it is more apparent than just an FID change of what happened.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

haydeniv’s picture

Here is the start of this. I could not get the linking to the file entity because everything is converted to text and so the hyperlink does not link because the filename changes in the hyperlink. Maybe someone else wants to take a stab at getting the linking to attachments to work. If it's too much trouble I can just do this with the file size improvements.

Settings Before:
diff-attachment-settings-before.png

Result Before:
diff-attachments-before.png

Settings After:
diff-attachments-settings-after.png

Result After
diff-attachments-after.png

Alan D.’s picture

How about just this?

$diff_items[$delta] = implode(variable_get('diff_file_property_separator', '; '), $output);

Which you would run this once to set:

variable_set('diff_file_property_separator', "\n");
Alan D.’s picture

Alan D.’s picture

Status: Needs review » Fixed

Pushed to dev bd5831a

Status: Fixed » Closed (fixed)

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