-
-
Notifications
You must be signed in to change notification settings - Fork 235
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
Labelling of items in Model tab pages (Equipment & Properties) #1264
Conversation
For each Item part of the model, its parent path in model is parsed from API response and relations added to the item. Allows path label to be displayed in Equipment and Properties pages. Signed-off-by: Gautier Taravella <tarag@mailbox.org>
…ts used as dividers. Signed-off-by: Gautier Taravella <tarag@mailbox.org>
Job #329: Bundle Size — 10.67MB (+0.02%).Changed metrics (4/8)
Changed assets by type (2/7)
|
Signed-off-by: Yannick Schaus <github@schaus.net>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really nice addition!
I just tested it on my prod and it works really well, the separator title trimming is a nice touch ;) Improving these home page cards is definitely something I want to push for the next release and I was actually planning something like that but never got around to it, so you beat me to it 🙂 Just know that it all might be revisited (see #753 for a related discussion). But I'm happy to have this improvement in the meantime while we discuss.
I just had a minor comment on some Stylus syntax that I ended up fixing myself since I had the branch checked out to test.
Thank you very much!
I'm glad you like it, thanks for the merge. I am really looking forward to have the default model tab pages providing a user-friendly and useful result without too much tweaking and I really think this patch helps in this matter. There is still one improvement relevant to sorting that I'll try to perform as you can see that the My goal is to be able to rely only on the auto-generated model pages - and some canvas pages of course 😉 I had not seen the discussion #753 while searching for related issues. I agree with the ideas discussed there, and I think it could further improve the usability when having many Points. I solve this now with a "maintenance" role where these advanced points are visible but this implies logging-in as another user which is not the best solution. Yet I believe my PR is still relevant even if some of the changes discussed there would be performed as it only deals with labelling. |
In order to have something understandable in Equipment/Properties model tab pages when having many Equipment and/or Properties of the same type (potentially having the same user-facing label), it is necessary to label them with something that allows to distinguish them from one another, which is usually the location of the equipment/point item.
This labelling is redundant with the labelling of the Location items to which these Equipment/Properties items may belong and leads to additional configuration work. In addition, it will clutter the pages in the Locations tab because all the items displayed there would have one common part which is the location, providing no user value in this context but more visual load (particularly problematic on small mobile screen where the end of the label, which may contain the most meaningful part will be trimmed).
This pull request provides some changes providing model context for the Equipment and Properties model tab pages. This should allow having simple labels definition for items belonging to the model:
Here is an illustration of the issue with the current version (3.2.0) with either short or complete labels used, and the resulting effect of the patch using the short labels.
Current status with model-redundant labels
![current-long labels](https://user-images.githubusercontent.com/11686092/148392831-c34ddb83-b04b-44b9-8aa1-e8c2df486308.gif)
Current status with short labels
![current-short labels](https://user-images.githubusercontent.com/11686092/148393628-fdc37823-f427-4c16-80b7-6b1f6bc9cc51.gif)
Pull request version with short labels
![patched-short labels](https://user-images.githubusercontent.com/11686092/148393686-d3bd90d9-5329-454e-9912-27713afcb98d.gif)