Page MenuHomePhabricator

Display in-lined fields for arrays with object items
Closed, ResolvedPublic

Description

The proposed design in the parent task T360445: Propose a control for collections displays the "title" and "label" fields in-lined instead of stacked. This is a fair UX improvement for JSON arrays which items are objects.
Note: Applying it to all objects could also make sense but it is out of the scope of this task

Design

Form for Help panel.png (2×1 px, 139 KB)

Acceptance criteria
  • JSON arrays which inform "items": { "type": "object" } should render the object properties in-line
Open questions
  • What's the maximum number of fields we should display in-lined? 2? 3?
  • How should the last row of fields behave? Expand over all the available space? Take the same width as the field in the precedent row (aka grid style)?

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Thank you for creating this task Sergio, some input on your open questions below:

What's the maximum number of fields we should display in-lined? 2? 3?

The maximum number would depend on what the fields are. If they elements are very directly related, then we should be putting them in the same row. We can set a maximum number of 3.

How should the last row of fields behave? Expand over all the available space? Take the same width as the field in the precedent row (aka grid style)?

I think we can solve this question by doing the following:

Collections proposal (1).png (1×752 px, 26 KB)

Can we add a sixth collection, name it 'Sixth link', and have it behave as the other links (with a field for the Label and a field for the Destination page?)? For the 'label' field, if we want this link to always be named as 'View more help articles', then we can have that field as read-only so it is unchangeable. This way that collection can take the same space as the others and be more aligned.

I think this is actively being worked on in context of T364846.

Etonkovidova subscribed.

Checked in eswiki betalabs - looks as per design:

Screen Shot 2024-06-14 at 11.12.46 AM.png (1×1 px, 163 KB)