[META] Once media is enabled, having the File, Image and Media reference fields all listed is confusing

Created on 21 March 2017, almost 8 years ago
Updated 5 February 2024, 12 months ago

Follow-up to #2831274: Bring Media entity module to core as Media module .

Problem/Motivation

In #2831274-200: Bring Media entity module to core as Media module , @effulgentsia commented:


This screenshot shows that when I add a new field somewhere (in this case to the Article content type), I'm presented a bunch of choices, and File and Media are two separate choices within the "Reference" section. How do I know how these differ?

Over the course of much discussion, we realized that this is really a Field UI problem, not a Media problem. Even though Media is becoming the preferred, and eventually the default, way to handle files and images in Drupal, there are still valid use cases for good ol' file and image fields (and in fact, both File and Image modules are hard dependencies of Media) -- for instance, if you do not want to support metadata or re-use. So the real problem is how to make it obvious to users what the difference is between "File", "Image", and "Media" -- or, for that matter, between any of the similarly-named field types that one can create.

Proposed resolution

Split the problem in two phases:

1) Short-term goal (8.5 target)

Reduce confusion for inexperienced site-builders, while still allowing advanced users to use whatever they need, basically improving labels and adding more help (as suggested in #42 and #51).

Field type plugins already support descriptions, so those descriptions will be shown below the select list displayed when creating a new field. Only the description of the currently selected field type will be shown. Many of the current descriptions are very developer-centric, so they will be wordsmithed in the follow-up issue #2930446: [PP-1] Improve field description texts for fields provided by core .

This work will be done in this issue.

2) Long-term goal

Reach a consensus on:

- If file/image fields will eventually be necessary at all (when Media is the preferred solution in core). (#47, #31 )
- If they are necessary, how / when to present them on the UI, versus the "media" field ( #34, #37, #43 )

Remaining tasks

Commit the patch.

User interface changes

The "Add field" page (/admin/structure/{entity-type}/manage/{bundle}/fields/add-field) will be extended to include new visual elements to help site builders understand the differences between the field types.

Screenshots with the the patch in #91 applied:

File field:

Image field:

Media field:

Video of the new descriptions being shown, with patch in #91 applied:

file_add_with_descriptions.mp4

API changes

None.

Data model changes

None.

🌱 Plan
Status

Active

Version

11.0 🔥

Component
Field UI 

Last updated 3 days ago

Created by

🇪🇸Spain marcoscano Barcelona, Spain

Live updates comments and jobs are added and updated live.
  • Needs usability review

    Used to alert the usability topic maintainer(s) that an issue significantly affects (or has the potential to affect) the usability of Drupal, and their signoff is needed. When adding this tag, make it easy to review the issue. Make sure the issue summary describes the problem and the proposed solution. Screenshots usually help a lot! To get sign-off on issues with the "Needs usability review" tag, post about them in the #ux channel on Drupal Slack, and/or attend a UX meeting to demo the patch and get direct feedback from designers/UX folks/product management on next steps. If an issue represents a significant new feature, UI change, or change to the general "user experience" of Drupal, use Needs product manager review instead. See the scope of responsibilities for product managers.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024