having hard time aligning cards/buttons …
Have question for whats the right way to align cards,
is there a way to properly align so it will work for both mobile and browser?
for example align to center.
i.e for below button-card
I use " - margin: 0px 0px 0px 180px" but im sure there’s a more reasonable way to do it.
But in different screens the button shift from the middle,
my question is how do i place card in absolute position so it will align it will align same way on different screen.
If that’s your yaml (and much better to post code rather than pictures of code), then the custom:button-card is sitting in a 3 column grid, so it will appear to the left of centre. That’s what grid card does. You might even have that nested in a horizontal-stack card?
If you’re using the standard masonry layout type and put one card in a view it should be horizontally centred automatically (unless there’s something weird about custom:button-card, I don’t use it).
If you want one column of cards, all horizontally centred, either put them in a vertical-stack or a single column grid card.
So we can see what you’re actually doing, go to edit mode, then the raw configuration editor (top right menu). Copy everything from there and paste it here. Before and after the code put three backticks to make it readable. If you can’t find the back tick, CTRL+E should insert them along with a placeholder for you to paste into.