Problem/Motivation

Found in #2726497-32: Deprecate text_with_summary.

Umami uses the 'text_with_summary' field, however none of the default content has a summary, and none of the listing views display the body field in summary/trimmed mode - they use cards with images and titles.

However if you create new content on an Umami site, you'll get the confusing UX of the teaser splitter allowing you to enter a summary that never shows up anywhere.

Steps to reproduce

Proposed resolution

Add a 'field_body' field using regular long text, update any theming, display modes, and default content etc. necessary to use that instead.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

Issue fork drupal-3425105

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

catch created an issue. See original summary.

catch’s picture

Issue summary: View changes

smustgrave made their first commit to this issue’s fork.

smustgrave’s picture

Not sure where the schema error is coming from.

smustgrave’s picture

Status: Active » Needs review

Think I found the issue. Had to use a new field name vs just "body"

smustgrave’s picture

Actually had to change a lot. This the route we will have to go other places since the "body" field is hardset to be text_with_summary.

markconroy’s picture

I think this looks like a great idea, but now I also have a worry about us having a field called body and a field called field_body if someone tries to add a new field to a content type and uses the "reuse existing field" approach. Also if you create a new content type it will automatically get the body field added.

I guess people don't need to be creating new fields and content types, since this is a fully formed demo.

I wonder could we disable the default body field from the UI fully?

catch’s picture

@markconroy there's a bit of a chicken and egg situation between this issue and other child issues of #2726497: Deprecate text_with_summary.

If we eventually remove the hard-coding of the 'body' field and make it uninstallable, then Umami would just be able to ignore it entirely.

If we want to keep the hard-coding of the 'body' field, then it might make sense to switch it to a standard text field for new installs, in which case this MR might not need to change anything.

smustgrave’s picture

Status: Needs review » Postponed

Opened a META to track decisions #3427095: [Meta] Deprecate text_with_summary

I'm postponing this till we decide what to do with the body field.

smustgrave’s picture

Status: Postponed » Needs review

Rebased and this is ready for review again.

markconroy’s picture

Status: Needs review » Reviewed & tested by the community

Tested againsta 11.x.

LGTM.

===
Thanks to Code Enigma for sponsoring my time to work on this.

catch’s picture

Status: Reviewed & tested by the community » Fixed

Had another look through this. I think the confusion between body vs. field_body is something a lot of real sites already have, and going to be less confusing than having the text summary widget which then never gets used. If we change how the body field works, we could eventually rename this again back to 'body' if we want to, or just leave it as is without the dormant body field.

Committed/pushed to 11.x, thanks!

  • catch committed 79d04f2a on 11.x
    Issue #3425105 by smustgrave, catch, markconroy: Don't use...

catch’s picture

Status: Fixed » Closed (fixed)

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