#Custom card size in section column

1 messages · Page 1 of 1 (latest)

dusky yoke
#

Hi,

is it possible to define how wide the custom (button) card is in the sections? I'd like it to fit only righthand side column.

I can define fixed width for it, but I feel that it does not resize the parent container for it, which is always 100% wide.

Thanks

#

Custom card size in section column

dusky yoke
#

Does anybody know? Whether it is just some missing property or not supported at all? Anybody mixing custom cards with this section layout?

bright narwhal
#

If the custom card hasn't been updated to support sections, then an alternative would be to use card_mod. Generally, adding something like this is all you need: ```yaml
card_mod:
style: |
ha-card {
width: 275px;
}

(I don't use Sections so my information may not be 100% accurate.)
dusky yoke
#

Thanks, I will try it out!

dusky yoke
#

@bright narwhal Yeah that was a good try, but it still does not seem to do the trick so that it would modify the whole upper container, so it takes the full width on the Section layout.

#

But that's fine, I can live with that, just wanted to know if there would be some easy trick I was just missing. Thanks for help!

bright narwhal
#

Sorry for the late response. When you said, custom (button) card, I read it as A custom button card and not THE custom:button-card. card_mod is actually not needed (for the most part) with the custom:button-card. It has its own styling options that can be configured.
But, I'm not sure what you mean by it would modify the whole upper container. Card_mod is only going to be able to modify the card that contains the code, nothing higher.
I don't think the custom:button-card has Section support yet. There seems to be some workarounds but nothing official. There's an open issue on Github about it. Section support #854