Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Scope: "Paragraphs EXPERIMENTAL" Widget
Scenario:
- Widget is configured with a default edit mode of "preview".
- An editor clicks the "Edit" button to open the paragraph sub form.
- An editor makes some edits.
- An editor clicks the "Collapse" button.
Current Results: The widget is displayed in the "closed" state with a paragraphs summary.
Expected Results: The widget is displayed in the "preview" state display the rendered preview with the updated values.
Comment | File | Size | Author |
---|---|---|---|
#2 | paragraphs-collapse-to-default-edit-mode-2892446-2.patch | 696 bytes | recrit |
|
Comments
Comment #2
recrit CreditAttribution: recrit commentedComment #3
miro_dietikerYeah, it kinda makes sense. :-)
But even if a paragraph is expanded=open by default, a user might want to define that the widget should display the Preview instead of the closed summary, if he clicks on "Collapse". I'm still not happy though to add a new setting. I feel like we should change the states and only have a "closed" state and determine if it displays summary or preview. Then the default mode setting just determines if Edit or Closed.
We still can care about this proposal in a follow-up.
But this issue should at least start with adding test coverage to check for the closed=preview expectation.
Comment #4
miro_dietikerThis is related to the autocollapse. :-)
Comment #5
miro_dietikerPostponing on that. Let's discuss it afterwards.
Comment #6
miro_dietikerWe have committed the autocollapse feature in Paragraphs EXPERIMENTAL widget.
Thus, you can enable that all paragraphs except the one in edit is collapsed.
At the same time, we refactored the closed mode: If a paragraph is collapsed, it always shows consistently a summary OR the preview based on configuration.
That makes this issue resolved. :-)
Comment #8
recrit CreditAttribution: recrit commented@miro_dietiker Thank you! I've just upgraded to 1.2+ and it works great!