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

Add optional boxed styling and error component to information widgets #1366

Closed
wants to merge 1 commit into from

Conversation

denispapec
Copy link
Sponsor Contributor

Proposed change

This change adds a new optional setting for all available information widgets: styleBoxed: true, which allows us to have more stylistic view of the header by groups single widget under a common boxed style. This PR also includes a separate error component for information widgets that unifies handling of error output.

Screenshot_20230416_003142
Screenshot_20230416_003053

Type of change

  • New service widget
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Other (please explain)

Checklist:

@shamoon
Copy link
Collaborator

shamoon commented Apr 16, 2023

Thanks for the PR.

I'm not sure how I feel about this aesthetically. Obviously that's subjective but I find the boxes just emphasizes all of the unequal gutters between columns and rows. If you want to keep the error change perhaps the rest of it should move to a discussion. I'm sure some folks will like it but some feedback before PR would be valuable

@benphelps
Copy link
Member

I'm not against adding a new style option for the widgets, but this highlights a problem that should be fixed first.

Header widgets need to be refactored to use wrapping components like the rest of the service widgets do. Applying a style to the widgets shouldn't require changing every widget individually. I think that should be taken care of first, so a change like this could be done in only a few files.

The option to enable this styling should live in the settings.yaml file where the other styling options are, not on each individual widget.

@shamoon
Copy link
Collaborator

shamoon commented Apr 27, 2023

Please re-open if you'd like to address the above.

@shamoon shamoon closed this Apr 27, 2023
@denispapec
Copy link
Sponsor Contributor Author

Hi, can you reopen the PR? It doesn't seem that I have rights?

I've pushed further changes to my branch and rebased the code to (almost) latest main branch, including the enhanced glances added in #1534 in mean time.

I agree about refactoring the widgets btw, I did already error component at that time as I've had issue to have unified widget style with error even at that point. The option now lives in settings.yaml.

My latest changes include all those widget refactored to shared components (to everything what makes sense to have), except for Kubernetes, Longhorn, Unifi widget as they don't follow any shared style (except for the wrapping Container component). Also, as I don't use these 3 technologies, I've faked API response to test. For completeness, here is screenshot with all widgets, having different states:
Screenshot_20230605_230724

And a screenshot of an real life example:
Screenshot_20230605_231148

Thanks for this great homepage!

@shamoon
Copy link
Collaborator

shamoon commented Jun 5, 2023

This can’t be reopened for whatever reason (perhaps your fork changed or whatever) so you can just open a new one

Copy link
Contributor

github-actions bot commented Feb 5, 2024

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new discussion for related concerns.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants