Lecture Notes Of Class 6 -
Grid Layout
Objectives
1.
Understand Tailwind's grid utilities.
2.
Create responsive grid layouts.
Introduction to Grid
Layout
A grid layout is a
powerful layout system for creating responsive designs. It allows developers to
arrange content into rows and columns efficiently. Tailwind CSS provides a set
of utilities to simplify working with CSS grids, enabling us to create
professional and responsive designs quickly.
1. Tailwind's Grid
Utilities
Tailwind offers a
comprehensive set of utilities for grid layout. Here are the core concepts:
a. grid Class
- The
grid class is used to define a container as a grid.
- Example:
html
Copy code
<div class="grid"></div>
b. Defining Columns: grid-cols-{n}
- The
grid-cols-{n} utility sets the number of columns in the grid.
- {n}
specifies the number of columns (e.g., 2, 3, 4).
- Example:
html
Copy code
<div class="grid
grid-cols-3">
<div>Item 1</div>
<div>Item 2</div>
<div>Item 3</div>
</div>
This creates a grid with
3 columns.
c. Adding Gaps: gap-{size}
- The
gap-{size} utility defines the spacing between grid items.
- {size}
can range from 0 to any Tailwind spacing value (e.g., gap-4, gap-8).
- Example:
html
Copy code
<div class="grid
grid-cols-3 gap-4">
<div>Item 1</div>
<div>Item 2</div>
<div>Item 3</div>
</div>
This adds spacing between
grid items.
d. Responsive Grids
- Tailwind
makes it easy to create responsive grids using breakpoints (e.g., sm,
md, lg).
- Example:
html
Copy code
<div class="grid
grid-cols-1 sm:grid-cols-2 md:grid-cols-3">
<div>Item 1</div>
<div>Item 2</div>
<div>Item 3</div>
</div>
- On
small screens, the grid has 1 column.
- On
medium screens, it has 2 columns.
- On
large screens, it has 3 columns.
2. Creating a Product
Gallery
We will design a simple product
gallery using Tailwind’s grid utilities.
Steps to Build a Product
Gallery
1.
Set Up the HTML Structure
html
Copy code
<div class="grid
grid-cols-3 gap-4">
<div class="p-4 border">Product
1</div>
<div class="p-4 border">Product
2</div>
<div class="p-4 border">Product
3</div>
<div class="p-4 border">Product
4</div>
<div class="p-4 border">Product
5</div>
<div class="p-4 border">Product
6</div>
</div>
o Explanation:
§ grid
makes the container a grid.
§ grid-cols-3
creates 3 columns.
§ gap-4
adds spacing between items.
§ Each
product is wrapped in a div with padding (p-4) and a border (border).
2.
Make the Gallery Responsive
html
Copy code
<div class="grid
grid-cols-1 sm:grid-cols-2 md:grid-cols-3 gap-4">
<div class="p-4 border">Product
1</div>
<div class="p-4 border">Product
2</div>
<div class="p-4 border">Product
3</div>
<div class="p-4 border">Product
4</div>
<div class="p-4 border">Product
5</div>
<div class="p-4 border">Product
6</div>
</div>
o Explanation:
§ grid-cols-1
ensures a single column on small screens.
§ sm:grid-cols-2
switches to 2 columns on small devices.
§ md:grid-cols-3
switches to 3 columns on medium devices.
3.
Add Styling
Use utility classes to enhance appearance.
html
Copy code
<div class="grid
grid-cols-1 sm:grid-cols-2 md:grid-cols-3 gap-4">
<div class="p-4 border rounded-lg
shadow-lg">
<img src="product1.jpg" alt="Product
1" class="w-full h-40 object-cover rounded-md">
<h3 class="mt-2 text-lg
font-bold">Product 1</h3>
<p class="text-sm
text-gray-600">$10.00</p>
</div>
<!-- Repeat for other products -->
</div>
o Explanation:
§ rounded-lg
adds rounded corners to each product card.
§ shadow-lg
adds a shadow for a 3D effect.
§ img
tag displays product images.
Activities
Activity 1:
Build a product gallery with grid-cols-3 and gap-4.
Activity 2: Add responsive design so the gallery adapts to different
screen sizes.
Activity 3: Enhance the gallery with images, shadows, and rounded
corners.
Conclusion
The grid layout is
a powerful way to design modern, responsive layouts. Tailwind’s grid utilities
make this process intuitive and efficient. By understanding how to use classes
like grid, grid-cols-{n}, and gap-{size}, you can create dynamic designs for a
variety of use cases.
Homework:
Create a responsive image gallery with 4 columns on large screens, 3 columns on
medium screens, and 2 columns on small screens. Add titles and descriptions to
each item.
4o
You said:
Write 10 assignments with
solution and explanation in detail on above concept
ChatGPT said:
ChatGPT
Assignments on Grid
Layout with Solutions and Explanations
Assignment 1: Basic Grid
Layout
Task:
Create a grid layout with 3 columns and 6 items. Add spacing of gap-4 between
the items.
Solution:
html
Copy code
<div class="grid
grid-cols-3 gap-4">
<div class="p-4 bg-blue-100">Item
1</div>
<div class="p-4 bg-blue-200">Item
2</div>
<div class="p-4 bg-blue-300">Item
3</div>
<div class="p-4 bg-blue-400">Item
4</div>
<div class="p-4 bg-blue-500">Item
5</div>
<div class="p-4 bg-blue-600">Item
6</div>
</div>
Explanation:
- grid-cols-3:
Creates 3 columns.
- gap-4:
Adds space between grid items.
- bg-blue-*:
Adds background colors to distinguish items.
Assignment 2: Responsive
Grid
Task:
Create a responsive grid layout that switches to 1 column on small screens, 2
columns on medium screens, and 3 columns on large screens.
Solution:
html
Copy code
<div class="grid
grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4">
<div class="p-4 bg-green-100">Item
1</div>
<div class="p-4 bg-green-200">Item
2</div>
<div class="p-4 bg-green-300">Item
3</div>
<div class="p-4 bg-green-400">Item
4</div>
<div class="p-4 bg-green-500">Item
5</div>
<div class="p-4 bg-green-600">Item
6</div>
</div>
Explanation:
- Breakpoints
like sm and lg control the grid's responsiveness.
- At
sm (small), the grid has 2 columns. At lg (large), it has 3 columns.
Assignment 3: Nested
Grids
Task:
Create a grid layout where one item contains another grid inside it.
Solution:
html
Copy code
<div class="grid
grid-cols-2 gap-4">
<div class="p-4 bg-gray-200">Item
1</div>
<div class="grid grid-cols-2 gap-2
p-4 bg-gray-300">
<div class="p-2 bg-gray-400">Nested
1</div>
<div class="p-2 bg-gray-500">Nested
2</div>
</div>
</div>
Explanation:
- The
second item contains another grid with 2 columns (grid-cols-2).
Assignment 4: Aligning
Items
Task:
Create a grid layout where items are center-aligned vertically and
horizontally.
Solution:
html
Copy code
<div class="grid
grid-cols-3 gap-4 place-items-center">
<div class="p-4 bg-yellow-100">Item
1</div>
<div class="p-4 bg-yellow-200">Item
2</div>
<div class="p-4 bg-yellow-300">Item
3</div>
</div>
Explanation:
- place-items-center:
Centers items vertically and horizontally.
Assignment 5: Auto-Row
Grid
Task:
Create a grid layout that automatically adjusts rows based on content height.
Solution:
html
Copy code
<div class="grid
grid-cols-3 gap-4 auto-rows-min">
<div class="p-4 h-24 bg-red-100">Short
Item</div>
<div class="p-4 h-48 bg-red-200">Tall
Item</div>
<div class="p-4 h-32 bg-red-300">Medium
Item</div>
</div>
Explanation:
- auto-rows-min:
Ensures each row adjusts its height to fit the tallest content.
Assignment 6: Custom
Column Widths
Task:
Create a grid layout with custom column widths: 1/4, 1/2, and 1/4.
Solution:
html
Copy code
<div class="grid
grid-cols-4 gap-4">
<div class="col-span-1 p-4
bg-purple-100">1/4</div>
<div class="col-span-2 p-4
bg-purple-200">1/2</div>
<div class="col-span-1 p-4
bg-purple-300">1/4</div>
</div>
Explanation:
- col-span-*:
Specifies how many columns an item spans.
Assignment 7: Grid with
Images
Task:
Create a gallery grid displaying images with equal spacing.
Solution:
html
Copy code
<div class="grid
grid-cols-3 gap-4">
<img src="image1.jpg" alt="Image
1" class="w-full h-auto">
<img src="image2.jpg" alt="Image
2" class="w-full h-auto">
<img src="image3.jpg" alt="Image
3" class="w-full h-auto">
</div>
Explanation:
- w-full
h-auto: Ensures images adjust to fit the column width.
Assignment 8: Justify
Items
Task:
Create a grid layout where items are aligned to the start of the container.
Solution:
html
Copy code
<div class="grid
grid-cols-3 gap-4 justify-items-start">
<div class="p-4 bg-pink-100">Item
1</div>
<div class="p-4 bg-pink-200">Item
2</div>
<div class="p-4 bg-pink-300">Item
3</div>
</div>
Explanation:
- justify-items-start:
Aligns items to the start of their column.
Assignment 9: Fixed
Number of Rows
Task:
Create a grid with 3 fixed rows and 2 columns.
Solution:
html
Copy code
<div class="grid
grid-cols-2 grid-rows-3 gap-4">
<div class="p-4 bg-indigo-100">Item
1</div>
<div class="p-4 bg-indigo-200">Item
2</div>
<div class="p-4 bg-indigo-300">Item
3</div>
<div class="p-4 bg-indigo-400">Item
4</div>
<div class="p-4 bg-indigo-500">Item
5</div>
<div class="p-4 bg-indigo-600">Item
6</div>
</div>
Explanation:
- grid-rows-3:
Fixes the number of rows to 3.
Assignment 10: Advanced
Responsive Gallery
Task:
Create a gallery with 1 column on small screens, 2 on medium, 4 on large
screens, and include hover effects on items.
Solution:
html
Copy code
<div class="grid
grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4">
<div class="p-4 bg-teal-100
hover:bg-teal-200 transition">Item 1</div>
<div class="p-4 bg-teal-100
hover:bg-teal-200 transition">Item 2</div>
<div class="p-4 bg-teal-100
hover:bg-teal-200 transition">Item 3</div>
<div class="p-4 bg-teal-100
hover:bg-teal-200 transition">Item 4</div>
</div>
Explanation:
- sm:grid-cols-2
and lg:grid-cols-4: Create responsive breakpoints.
- hover:bg-teal-200:
Changes background color on hover.
- transition:
Adds smooth hover effects.
These assignments will
help students master Tailwind's grid utilities and build responsive, visually
appealing layouts.
4o
You said:
write 50 MCQs for the
concept above with explanation
ChatGPT said:
ChatGPT
50 Multiple Choice
Questions on Tailwind CSS Grid Layout
Each question is followed
by the correct answer and an explanation.
Basic Concepts
1.
What is the primary utility class in
Tailwind to enable grid layout?
a) flex
b) grid
c) block
d) inline-grid
Answer: b) grid
Explanation: The grid class applies a CSS Grid layout to the container.
2.
Which class defines the number of
columns in a grid layout?
a) grid-cols
b) grid-cols-*
c) col-span-*
d) grid-rows-*
Answer: b) grid-cols-*
Explanation: The grid-cols-* class sets the number of columns in the
grid.
3.
How do you specify a gap between grid
items?
a) space-x-*
b) gap-*
c) justify-items
d) row-gap-*
Answer: b) gap-*
Explanation: The gap-* class sets uniform spacing between grid rows and
columns.
4.
What does the class grid-cols-3 do?
a) Creates 3 rows
b) Creates 3 columns
c) Creates 3 grid areas
d) Sets the gap size to 3
Answer: b) Creates 3 columns
Explanation: The grid-cols-3 class creates a grid with 3 columns.
5.
Which class makes the grid responsive
by setting the number of columns based on screen size?
a) sm:grid-cols-*
b) flex-wrap
c) grid-rows-*
d) hidden
Answer: a) sm:grid-cols-*
Explanation: Responsive grid column classes like sm:grid-cols-* adjust
the grid layout at specific breakpoints.
Intermediate Concepts
6.
What does place-items-center do in a
grid layout?
a) Aligns items to the left
b) Aligns items to the center
c) Adds spacing between items
d) Creates a column layout
Answer: b) Aligns items to the center
Explanation: The place-items-center class centers items both
horizontally and vertically.
7.
Which class aligns grid items at the
start of their column?
a) justify-items-start
b) align-items-start
c) place-items-start
d) grid-start
Answer: a) justify-items-start
Explanation: The justify-items-start class aligns items to the start of
their columns.
8.
How do you define the height of rows
automatically based on content?
a) row-auto
b) auto-rows-min
c) gap-rows-auto
d) rows-flex
Answer: b) auto-rows-min
Explanation: The auto-rows-min class sets row height to fit the content.
9.
Which class specifies how many
columns a grid item should span?
a) grid-cols-*
b) col-span-*
c) col-start-*
d) col-gap-*
Answer: b) col-span-*
Explanation: The col-span-* class specifies the number of columns an
item spans.
10.
What does grid-rows-3 define?
a) A grid with 3 columns
b) A grid with 3 rows
c) A responsive grid
d) A grid with 3 areas
Answer: b) A grid with 3 rows
Explanation: The grid-rows-3 class creates a grid with 3 rows.
Advanced Concepts
11.
Which class creates equal spacing
between rows only?
a) gap-y-*
b) row-gap-*
c) gap-x-*
d) space-y-*
Answer: a) gap-y-*
Explanation: The gap-y-* class defines vertical gaps between rows.
12.
How do you add hover effects to grid
items?
a) hover:gap-*
b) hover:bg-*
c) hover:grid-cols-*
d) hover:place-items-*
Answer: b) hover:bg-*
Explanation: The hover:bg-* class changes the background color when an
item is hovered.
13.
What does the lg:grid-cols-4 class
achieve?
a) Creates 4 columns on large screens
b) Creates a gap of 4
c) Creates 4 rows on large screens
d) Aligns grid items to the right
Answer: a) Creates 4 columns on large screens
Explanation: The lg:grid-cols-4 class adjusts the grid to 4 columns at
large breakpoints.
14.
Which class centers items only
vertically?
a) place-items-center
b) align-items-center
c) place-content-center
d) items-center
Answer: d) items-center
Explanation: The items-center class vertically centers items in their
container.
15.
How do you make a grid container
behave like a block element?
a) grid
b) inline-grid
c) block-grid
d) flex-grid
Answer: a) grid
Explanation: The grid class sets the display property to grid, which
behaves like a block container.
This list includes 15
MCQs. If you'd like, I can provide the remaining 35 to complete the set. Let me
know!
4o
You said:
yes
ChatGPT said:
ChatGPT
Continuing with the
Remaining 35 MCQs
Advanced Concepts
(Continued)
16.
What does the class sm:gap-6 do?
a) Sets the gap size to 6 for all screen sizes
b) Sets the gap size to 6 for small screens and above
c) Sets the gap size to 6 only for medium screens
d) Sets no gap on small screens
Answer: b) Sets the gap size to 6 for small screens and above
Explanation: The sm:gap-6 class applies a gap of 6 starting from small
screen breakpoints (sm) and above.
17.
Which class is used to justify grid
items to the center?
a) justify-center
b) items-center
c) place-items-center
d) align-items-center
Answer: a) justify-center
Explanation: The justify-center class centers items horizontally in the
grid container.
18.
What does the grid-flow-row class do?
a) Aligns grid items in a single column
b) Ensures items flow in rows by default
c) Allows items to wrap into columns
d) Aligns grid items to the right
Answer: b) Ensures items flow in rows by default
Explanation: The grid-flow-row class specifies that items are laid out
in rows.
19.
What is the purpose of col-start-3?
a) Starts a column from the third row
b) Makes the grid column span three columns
c) Starts the grid item at the third column
d) Creates a grid layout with three columns
Answer: c) Starts the grid item at the third column
Explanation: The col-start-3 class positions an item to begin at the
third column.
20.
How do you ensure grid rows flow into
the next available space?
a) grid-flow-row
b) grid-flow-col
c) grid-flow-dense
d) grid-flow-space
Answer: c) grid-flow-dense
Explanation: The grid-flow-dense class ensures that rows are packed into
available space.
Practical Use Cases
21.
How do you create a responsive grid
with 2 columns on medium screens and 4 on large?
a) grid-cols-2 lg:grid-cols-4
b) lg:grid-cols-2 grid-cols-4
c) grid-cols-2 lg:cols-4
d) grid-md-2 grid-lg-4
Answer: a) grid-cols-2 lg:grid-cols-4
Explanation: This class combination sets 2 columns by default and
switches to 4 columns on large screens.
22.
Which class would you use to define a
grid item that spans 2 rows?
a) row-span-2
b) grid-row-2
c) span-rows-2
d) row-start-2
Answer: a) row-span-2
Explanation: The row-span-2 class makes the grid item span 2 rows.
23.
How do you align content within the
grid area at the bottom?
a) align-content-bottom
b) place-content-bottom
c) content-end
d) justify-content-bottom
Answer: c) content-end
Explanation: The content-end class aligns grid content to the bottom.
24.
What does the gap-x-4 class specify?
a) Horizontal gaps between grid columns
b) Vertical gaps between grid rows
c) Both horizontal and vertical gaps
d) No gaps
Answer: a) Horizontal gaps between grid columns
Explanation: The gap-x-4 class defines a horizontal gap size of 4.
25.
Which class makes a grid container
behave inline?
a) inline-grid
b) grid-inline
c) flex-inline
d) inline-flex
Answer: a) inline-grid
Explanation: The inline-grid class applies an inline grid display
property.
Testing Understanding
26.
What does the auto-cols-min utility
do?
a) Makes column widths expand to fill available space
b) Ensures minimum column width based on content
c) Aligns columns to the left
d) Sets all column widths to the same size
Answer: b) Ensures minimum column width based on content
Explanation: The auto-cols-min class automatically sets column widths to
fit their content.
27.
What does the place-content-center
class do?
a) Aligns items to the center of their cells
b) Centers the entire content of the grid
c) Spaces grid rows evenly
d) Aligns columns to the center
Answer: b) Centers the entire content of the grid
Explanation: The place-content-center class centers the content inside
the grid container.
28.
Which class sets the number of rows
in a grid?
a) grid-rows-*
b) rows-span-*
c) rows-*
d) grid-cols-*
Answer: a) grid-rows-*
Explanation: The grid-rows-* class sets the number of rows in a grid
container.
29.
What is the role of sm:grid-rows-2?
a) Adds 2 rows at small breakpoints
b) Adds 2 rows for all screen sizes
c) Adds 2 rows for medium screens
d) None of the above
Answer: a) Adds 2 rows at small breakpoints
Explanation: The sm:grid-rows-2 class specifies a 2-row layout starting
at small screens.
30.
How do you ensure all grid rows are
equally spaced vertically?
a) gap-y-*
b) grid-y-*
c) row-gap-*
d) space-y-*
Answer: a) gap-y-*
Explanation: The gap-y-* class creates equal vertical spacing between
rows.
If you'd like further
questions to round this out, I can provide additional queries focusing on edge
cases, advanced responsive layouts, and practical coding scenarios. Let me
know!
4o
You said:
rest 20
ChatGPT said:
ChatGPT
Remaining 20 MCQs for
Tailwind CSS Grid Layout
Advanced Use Cases
31.
Which class is used to align grid
items to the end of a column?
a) col-align-end
b) justify-end
c) col-start-end
d) align-end
Answer: b) justify-end
Explanation: The justify-end class aligns grid items to the end of the
column.
32.
What does the grid-flow-col class
achieve?
a) Creates columns that span rows
b) Forces items to flow into columns
c) Aligns columns to the center
d) Creates rows that span columns
Answer: b) Forces items to flow into columns
Explanation: The grid-flow-col class ensures grid items are arranged in
columns.
33.
Which utility creates an automatic
row height based on the tallest item in the row?
a) auto-rows-max
b) auto-rows-min
c) auto-rows-auto
d) auto-cols-max
Answer: a) auto-rows-max
Explanation: The auto-rows-max class makes rows adjust their height to
fit the tallest item.
34.
Which class is used to define equal
spacing in both horizontal and vertical directions?
a) gap-4
b) space-4
c) auto-gap-4
d) grid-gap-4
Answer: a) gap-4
Explanation: The gap-4 class creates equal spacing between rows and
columns.
35.
How do you specify that a grid item
spans 4 columns?
a) col-span-4
b) grid-cols-4
c) span-cols-4
d) grid-span-4
Answer: a) col-span-4
Explanation: The col-span-4 class makes a grid item span 4 columns.
36.
What does the place-self-auto class
do?
a) Places grid items in an automatic position
b) Aligns the grid container automatically
c) Resets alignment to the default (auto)
d) Creates an automatic gap between items
Answer: c) Resets alignment to the default (auto)
Explanation: The place-self-auto class resets both horizontal and
vertical alignment to their default values.
37.
Which utility applies vertical
centering for grid items?
a) align-center
b) items-center
c) justify-items-center
d) place-items-center
Answer: b) items-center
Explanation: The items-center class vertically centers items within
their grid cells.
38.
What is the effect of lg:grid-cols-6?
a) Creates a 6-column layout for all screen sizes
b) Creates a 6-column layout for large screens and above
c) Creates 6 rows for large screens and above
d) Creates a single-column layout for small screens
Answer: b) Creates a 6-column layout for large screens and above
Explanation: The lg:grid-cols-6 class sets up 6 columns starting at the
large screen breakpoint.
39.
Which class defines a default grid
layout with no gaps?
a) grid
b) grid-nogap
c) grid-none
d) grid-default
Answer: a) grid
Explanation: The grid class defines a grid container without any gaps
unless explicitly added using gap utilities.
40.
How do you set the starting position
of a grid item at the 4th row?
a) row-start-4
b) row-begin-4
c) grid-row-start-4
d) row-position-4
Answer: a) row-start-4
Explanation: The row-start-4 class positions the item to begin at the
4th row.
Responsive Grid Layout
41.
Which class allows an item to span
multiple columns on large screens?
a) lg:col-span-*
b) col-lg-span-*
c) lg:grid-span-*
d) lg:span-cols-*
Answer: a) lg:col-span-*
Explanation: The lg:col-span-* class specifies column spanning on large
screens.
42.
What does the md:grid-cols-3 class
specify?
a) A 3-column layout for medium screens and above
b) A 3-row layout for medium screens and above
c) A 3-column layout for all screen sizes
d) A single-column layout for small screens
Answer: a) A 3-column layout for medium screens and above
Explanation: The md:grid-cols-3 class sets up 3 columns starting at the
medium screen breakpoint.
43.
What utility ensures uniform height
across all grid rows?
a) rows-auto
b) auto-rows-min
c) auto-rows-auto
d) row-span-auto
Answer: c) auto-rows-auto
Explanation: The auto-rows-auto utility automatically adjusts rows to
have uniform height.
44.
What does gap-y-8 do?
a) Sets horizontal gaps to 8
b) Sets vertical gaps to 8
c) Sets both vertical and horizontal gaps to 8
d) Removes all gaps
Answer: b) Sets vertical gaps to 8
Explanation: The gap-y-8 class defines a vertical gap of size 8.
45.
How do you center grid items both
horizontally and vertically?
a) place-center
b) items-center justify-center
c) place-items-center
d) Both b and c
Answer: d) Both b and c
Explanation: Both items-center justify-center and place-items-center
achieve centering in both directions.
46.
Which class starts a grid item at the
2nd column?
a) col-start-2
b) start-col-2
c) grid-column-2
d) grid-col-start-2
Answer: a) col-start-2
Explanation: The col-start-2 class starts an item at the 2nd column.
47.
What does grid-cols-none do?
a) Removes all grid columns
b) Creates a single-column grid layout
c) Specifies that column count is determined dynamically
d) Removes column gaps
Answer: c) Specifies that column count is determined dynamically
Explanation: The grid-cols-none class relies on content to determine
column counts.
48.
How do you add a 10-pixel gap between
columns?
a) gap-10
b) gap-x-10
c) cols-gap-10
d) space-x-10
Answer: b) gap-x-10
Explanation: The gap-x-10 class sets a horizontal gap of 10 pixels.
49.
Which utility creates a responsive
grid with columns filling available space?
a) grid-cols-fill
b) grid-cols-auto
c) grid-cols-[repeat(auto-fill)]
d) auto-cols-fill
Answer: c) grid-cols-[repeat(auto-fill)]
Explanation: This class creates a responsive grid where columns
dynamically fill the available space.
50.
What does the sm:grid-flow-col class
do?
a) Makes items flow in columns for small screens and above
b) Sets columns for all screen sizes
c) Adds small gaps between columns
d) Aligns items to the column center
Answer: a) Makes items flow in columns for small screens and above
Explanation: The sm:grid-flow-col utility specifies column flow starting from small breakpoints.

No comments:
Post a Comment