Dashboard Templates - where are they? Can they be modified? References in Layout window

strong textIā€™ve been using Dashboard instances with shade screen and awning devices (made by Somfy, via ZRTSII Z-wave controller) using Denny Pageā€™s driver. Everything worksā€¦ but in trying to improve the Dashboard UI - via custom icons, color changes based on device state / attribute, etc., I feel like Iā€™ve discovered a disconnect somewhere in the ā€˜back-endā€™.

Pardon my description if I get any terminology wrong; pictures included to express the issue better. Knowing how ā€˜pickyā€™ computers are, Iā€™m suspicious that the inconsistency in references to ā€œshadeā€ and ā€œshadesā€ is the reason Iā€™m unable to get things to work as desired.

First pic shows one of the dashboard instances using the ā€œShadeā€ template.

Next pic shows layout tab with several instances of ā€˜ ā€œtemplateā€: ā€œshadesā€ ā€˜. Note SHADES!

Doesnā€™t that mean that the code in the layout tab is referencing a different template in the underlying database? (If so, that explains why any changes I attempted to make in the layout code didnā€™t work.)

Please explain conceptually how this is implemented, and whether any provisions are made for users to create alternative templates.

I see the same thing (Shade and Shades), without having edited the layout text itself, but having used and adjusted the colors for the Shade(s) template. In saying that, my changes, I think, have worked.... Though I tend to heavily edit things via CSS, so I could be masking the issue you point out....

Not to dismiss the issue, if indeed there is one, there are ways to tweak most things through the Custom CSS route if you need to, so if an issue in the template setup is standing in your way, we should be able to work around it, whilst allowing the developers to address any issues you have raised.

Thanks for confirming the apparent problem. I have thus far avoided the learning adventure that awaits in CSS-land, so Iā€™m hopeful that someone on the Support Team can still address it, and hopefully provide a little top-level explainer on the Template ecosystem. :nerd_face:

1 Like

What exactly is broken (naming inconsistency notwithstanding)?

The result of the naming / reference disconnect is that user changes to dashboard items (made through the provided tools, or via direct editing of the Layout JSON) donā€™t have the desired effect. Iā€™m guessing that, under the hood, there are Shade tables in the database, and there are Shades tables in the database, or something to that effect.

In the screenshots above, the auto-generated JSON references a Shades templateā€¦ but when adding a tile the only template option available is Shade. If we assume that the Shade template is the ā€˜realā€™ one, then its definition (and user-selected color-mapping to states, custom icons, etc.) are not applied to Layout tiles of template type Shades.

I hope that makes sense to you. Without any understanding of whatā€™s under the hood, I may not be explaining it very well. Note: As an experiment I tried to edit the references in the JSON to be ā€œShadeā€ - hoping that might resolve the problem - but such edits fail when I hit the save button. If you can explain the template ecosystem, I would appreciate it!

I'd like to revive this thread, I use the Samrtwings built in driver and the color templates for shade do not work for open and close. @gopher.ny

@sburke781 how did you work around this one?

I vaguely remember getting inconsistent results, so I may have jumped the gun on that one, but the CSS option is always there, would just need to lookup how to apply the different state options via CSS in the Noobs CSS thread, i.e. lookup the classes assigned for the different shade states and include CSS to style the tile differently depending on the state.

Alternatively, you could try tweaking the name of the template entries in the layout section for different state colors, to see if that will hold and take effect.

Yeah, I am a little familiar with CSS and the JSON template, but just can't seem to get this one to work. I think this has been an issue for a while, found lots of threads with shade color template issues.
I did edit a driver to have capability switch so the shade would be on and off. I can get it to work like this as the template works for on and off, but not for open and close.

I think some of it is coming back to me now, mostly likely I was mistaken when saying I had a setup that worked..... :frowning: The open / closed classes are applied to a div a few levels down to from the top-level tile. That's not to say it can't be done, just not sure how just yet.

Exactly, that's what I saw as well. It's in the tile.primary class which is stacked under the tile.shades then tile.contents, like you said a couple levels down. Either way i think there is an issue with the dashboard not seeing the open and closed or something like that.

In my case it picks up the opening and closing correctly if I initiate it from within the Device edit page, i.e. the CSS class is assigned as expected to the tile-primary div, but if I initiate the change from outside HE (I have a Bond Bridge) the attribute on the device and likewise the div class does not change. I don't think that is a symptom of the issue we are trying to solve here, this thread is more about how the tile is presented when the accurate information is available.