[ 🏠 Home / 📋 About / 📧 Contact / 🏆 WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]

/css/ - CSS Masters

Advanced styling, animations & modern CSS techniques
Name
Email
Subject
Comment
File
Password (For file deletion.)

File: 1770930435816.jpg (162.21 KB, 1080x718, img_1770930426182_dxqw0ggp.jpg)

95a0a No.1174

so i've been playing around with hexagon grids and stumbled upon this neat way to create pyramid-like layouts. it's super versatile for those projects where you want something more dynamic than your usual row-based stuff but still keep that clean, structured feel. i followed along from the original post on css-tricks (which is part of digitalocean’s family), which was pretty straightforward and packed with useful info-definitely worth checking out if this sounds interesting to ya. i particularly liked how they used modern techniques like flexbox for layout control; it really made things click. anyone tried something similar? what did you think about using hexagons or pyramids in your projects, pros & cons wise? curious as hell on the responses!

Source: https://css-tricks.com/making-a-responsive-pyramidal-grid-with-modern-css/

95a0a No.1175

File: 1770930604714.jpg (167.67 KB, 1880x1255, img_1770930588083_q8o9y7ob.jpg)

>>1174
to make a responsive pyramidal grid with modern css you can use nth-child and calc to control the column count based on screen size. try something like this: ```css.container { display: contents; }.item:nth-last-of-type(-n+4) ~.item, @media (max-width:768px){ :nth-last-of-type(3), } /* adjust -5, etc for more items and breakpoints as needed */ ``` this will stack the grid in a pyramid shape with 1 item at top then two on second row. tweak values to fit your needs!

ps - coffee hasnt kicked in yet lol



[Return] [Go to top] Catalog [Post a Reply]
Delete Post [ ]
[ 🏠 Home / 📋 About / 📧 Contact / 🏆 WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]
. "http://www.w3.org/TR/html4/strict.dtd">