Fancy Nancy
KPCKevin Powell - Community
•Created by Nibelung Valesti on 11/7/2024 in #front-end
Two Column Layout, but the other one goes to edge.
Oh, neat! That is indeed a much more elegant solution. Updating my previous answer:
7 replies
KPCKevin Powell - Community
•Created by Nibelung Valesti on 11/7/2024 in #front-end
Two Column Layout, but the other one goes to edge.
Use relative positioning + negative margin on the image container.
Example:
7 replies
KPCKevin Powell - Community
•Created by Zempai on 11/7/2024 in #front-end
CSS – managing grid-template-columns sizes with classes
I'm not sure I fully understand your question. You want to add an on-demand padding in a grid layout without disturbing the content’s alignment, using CSS techniques that don’t rely on
::before
or ::after
pseudo-elements, nor require extensive redefinition of padding-inline?
Maybe add extra empty columns on each side for padding? Something like this:
Created 5 columns in the container. 1fr
on both sides for flexible spacing, wrapping minmax(0, 1rem)
on both sides in case you apply the padding class.
If that is indeed what you meant, are you sure you're asking the correct questions? What is your use case? What design are you attempting to achieve?
If that is not what you meant, I apologize, and ask that you further clarify or elaborate on the question.5 replies