Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement: Description/Help for metadata field definitions #391

Closed
michaeltlombardi opened this issue Sep 2, 2022 · 5 comments
Closed
Labels
enhancement New feature or request Project: v8.1.0

Comments

@michaeltlombardi
Copy link

Is your feature request related to a problem? Please describe.

I'm working on a default frontmatter.json definition for users of my Hugo theme to be able to leverage because Front Matter seems like a tool that is absolutely going to help me give those users a more delightful experience. While trying to configure the metadata fields, I noticed that they don't have something like an optional description key, which would help keep users from having to look things up.

Describe the solution you'd like

Ideally, there would be an optional description or help key (not fussed about the name) for metadata fields which would:

  • Display when a user hovers over that field name in the UI
  • Display in fainter text beside or below the field name

I think from a UX perspective, show-on-hover by default with an option to always display would be really stellar. If no description is provided, you get no hover text nor a description after the field name.

Describe alternatives you've considered

I could extend the title key for the metadata fields to include this information, but that could be distracting or confusing, I think.

Additional context

N/A

@michaeltlombardi michaeltlombardi added the enhancement New feature or request label Sep 2, 2022
@michaeltlombardi michaeltlombardi changed the title Enhancement: Enhancement: Description/Help for metadata field definitions Sep 2, 2022
@estruyf
Copy link
Owner

estruyf commented Sep 16, 2022

What do you think about this:

image

First implementation and it is coupled to the #369 feature.

Usage

Add the description property to the field configuration, and you should see the message appear in the panel.

@michaeltlombardi
Copy link
Author

That looks great to me! That definitely makes it easier to provide context as close to the work as possible for users. 😊

estruyf added a commit that referenced this issue Sep 16, 2022
@estruyf
Copy link
Owner

estruyf commented Sep 16, 2022

New beta version is coming up fo you to test.

@michaeltlombardi
Copy link
Author

Confirmed and it looks good! I tried using newlines which didn't work, but I think that's probably fine.

Screenshot of the updated view with per-field descriptions, the markdown file, and the frontmatter json

@estruyf
Copy link
Owner

estruyf commented Sep 17, 2022

It just a simpel description line that is supported, but this gave me an idea.

Would a divider and header (which can include a description) make sense? That way, you can split the fields in sections.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Project: v8.1.0
Projects
None yet
Development

No branches or pull requests

2 participants