2022.11: Card borders

Try:

no-borders:
  modes:
    dark:
      # I think there must be at least one setting here to get this to work, try for example
      text-color: '#ffffff'
  card-mod-theme: no-borders
  card-mod-root-yaml: |
    .: |
      ha-app-layout {
        --ha-card-border-width: 0px;
        --ha-card-border-radius: 1px
      }
2 Likes

I agree.
But that should be for those - who want to have the ā€œdefaultā€ theme - just without the round bordersā€¦ similar as it was with the original ā€œoutlineā€ theme from @frenck :wink:

Afaik, you canā€™t add these two lines to a theme that does not appear in the ā€œthemesā€ folder?

there is no such thing.

you either dont have themes configured (and by default use only the ā€˜defaultā€™ theme), or you do have themes configured.

if the former, you can use the new edits by creating a first smal theme, with only those lines. And select that theme in the selector. (you can not add anything to the ā€˜defaultā€™ theme)

if the latter, add it to any/all themes and continue like before.

easily done with a yaml anchor on the top theme in your file:

  <<: &generic
    ha-card-border-radius: 0px
    ha-card-border-width: 0px
    any other stuff you want in all other themes

and inject in all below themes in the file:

  <<: *generic

thatā€™s what I did - and thatā€™s what I would like to share on HACS for those who donā€™t want to use one of the many themes because they still like the color-theme from the default installation - but donā€™t want to have rounded cards :wink:

so - basically - just a ā€œdefaultā€ theme without ā€œradiusā€
grafik

Still trying to figure out how to do the switch between dark / light modeā€¦ since this does not seem to work in the ā€œSet themeā€ serviceā€¦

thatā€™s not how that works eitherā€¦

frontend.set_theme does what is says, set a theme.

In a theme you can have specifics for light and dark_mode. If not, again, it follows the settings for default
dark/light mode follow the mode your device is in.

however, you can set themes, and not configure those dark/light modes at all. I dont use them, and dont use dark mode either. Eg I switch to dark themes on certain occasions (below horizon/away) or red theme (alarm triggeredā€¦)

So depending in your wishes, you can customize away

you can see here frontend/ha-style.ts at c810c67a539f16f250d30f755832ebd9ad990707 Ā· home-assistant/frontend Ā· GitHub and here frontend/styles.ts at c810c67a539f16f250d30f755832ebd9ad990707 Ā· home-assistant/frontend Ā· GitHub what the default settings are

yes. but even if I do have modes for dark and light, it seems that the service canā€™t set them.

example?
I do have a google themeā€¦ that does have the following modes:

this is the setting in the service:

Executing ā€œcall serviceā€

User Setting is ā€œBackend Selectedā€
grafik

ā†’ no change.

The same user-Settings, the same theme ā†’ Light mode selected:

executing ā€œcall serviceā€

the theme will be changedā€¦ but only the light mode is available.

I can ONLY change the mode within the User settings:
grafik

So in my eyes, the ā€œModeā€ selection in the service seems not to work?!
And the theme selection itself does ONLY work, when light mode has been selected.

maybe move this to a separate thread as it is not about the release, but about the more generic theme workings.
it would also give you some more playground and experiment with Home Assistant Frontend - Home Assistant

EDIT: I went this route instead and also added a resource in the browser instead (the companion app doesnā€™t want to load new modules that way without a wipe).

Frenckā€™s theme is released under the MIT license, so your question is answererd

I would argue the same about running non-HA containers on docker when running Supervised.

Thatā€™s the ticket!

no-borders:
  modes:
    dark:
      text-color: '#ffffff'
  card-mod-theme: no-borders
  card-mod-root-yaml: |
    .: |
      ha-app-layout {
        --ha-card-border-width: 0px;
        --ha-card-border-radius: 1px
      }

finally gives me back my old dashboard :heart_eyes:
image

instead of this :frowning:
image

Many thanks for your advice!

1 Like

So we know how to fix borders and their radius. What about shadows?
Or maybe generally there is a link with the list of HA CSS identifiers?

are you using the HomeAssistant default theme? or any other theme?

1 Like

Do you understand that any attempts of fixing a design by themes is a WRONG way?
Wrong - at least because not all results depend on a value of some variable.

Great, thanks, that repository is helpful and self-explaining enough.

The CSS identifiers complete list is still nice to have.

Heā€™s giving people help to change the look. No reason to get pissed off at him.

5 Likes

hmā€¦ I donā€™t see any issues with it.
The developers have made a design decission for their software.

You can like it - or not.
If a customization does not work anymore in the way it was before the update, you need to fix it for you.
Customization of Design elements is - afaik not the responsibility of the HA Devs.

If you want to stick to the ā€œold HA defaultā€ theme - because you donā€™t like the new rounded edges, a theme can be an easy way to solve itā€¦ It is not supposed to fix any other ā€œcustomizationā€ā€¦ It should just provide what it provides. The Pre 2022.11 look.
Nothing more. :man_shrugging:

2 Likes

You misunderstood me. This is not about disrespect of helping. This is about hilighting a fact that themeing may not help.

Already said - this is not only about changing one variable.

1 Like

The theming works, the card mod also works for the default theme.

3 Likes