VOOZH about

URL: https://www.geeksforgeeks.org/css/primer-css-inline-block-grids/

⇱ Primer CSS Inline block grids - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Primer CSS Inline block grids

Last Updated : 23 Jul, 2025

Primer CSS is a free open-source CSS framework that is built with the GitHub design system to provide support to the broad spectrum of Github websites. It creates the foundation of the basic style elements such as spacing, typography, and color. This systematic method makes sure our patterns are steady and interoperable with every other. Its approach to CSS is influenced by Object-Oriented CSS principles, functional CSS, and BEM architecture. It is a highly reusable model.

Primer CSS grid system works with various layout utilities for different outputs. Many columns can be adjusted across breakpoints in a container for getting responsive results.

Primer CSS inline-block grids class:

  • d-inline-block: This class is used to set an inline-block grid along with Primer CSS grid column width classes.

Syntax:

<div>
 <div class="d-inline-block border col-2">
 ...
 </div>
 <div class="d-inline-block border col-2">
 ...
 </div>
</div>

Example 1: The following code demonstrates the column widths using the d-inline-block class in the HTML div element.

Output:

👁 Image
 

Example 2: The following code shows that the developer can use column widths and other utilities on HTML list elements as per the application need. 

Output:

👁 Image
 

Reference: https://primer.style/product/css-utilities/#inline-block-grids

Comment