Skip to content

Forms: "fixed" fields UI #3476

@JohnXLivingston

Description

@JohnXLivingston

Describe the bug

Currently form "fixed" fields are rendered using the form-help CSS class.

If we take a look to the Prosody MUC config forms, such fields are used as titles to separate fields into thematics.

The form-help CSS class renders with a 90% font-size, and the --subdued-color color, as if the text was less important than normal text. This gives a bad UX for room config forms:

image

Of course, there might be forms where these fields are not titles, but help text. So we can't just assume that these texts should be render as titles.

XEP-0045 does not specify anything about how fixed fields should be interpreted.

XEP-0004 says:

  • (Note: To provide a description of a field, it is RECOMMENDED to use a <desc/> element rather than a separate <field/> element of type "fixed".)
  • The field is intended for data description (e.g., human-readable text such as "section" headers) rather than data gathering or provision.

To Reproduce

Open a MUC room config form, provided by a Prosody server.

Expected behavior

As said above, i think we can't assume neither that these fields should be "help" text, neither titles.

So I think they should just render as normal text.

Here is what happen if we just remove the form-help class:

image

This seems fine for me.
So, what i suggest: rename templates/form_help.js to templates/form_fixed.js, and remove the form-help class from the p tag.

If you are ok with that, i can make a PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions