Professional Documents
Culture Documents
Computing
(CCIS1101)
Mark Christopher Borja
Lesson 9:
Bootstrap
Objectives of this
Discussion:
• Explain the fundaments of the Bootstrap framework,
including its grid system, components, and utility
classes..
Example (Local):
• Download the Bootstrap files
from getbootstrap.com.
• Place the CSS and JS files in your
project directory.
• Link to them in your HTML file.
(2) Downloading Bootstrap
Example (Local):
• Download the Bootstrap files
from getbootstrap.com.
• Place the CSS and JS files in your
project directory.
• Link to them in your HTML file.
(2) Downloading Bootstrap
Bootstrap Layout
Understanding Grid
System
Grid Layout - A system for organizing
content into rows and columns.
Responsiveness:
- The grid system is designed to be
responsive.
- Content automatically adjusts to fit
various screen sizes.
Understanding Grid
System
Mobile-first approach - Content
starts as a single column on small
screens and scales up
Understanding Grid
System
Mobile-first approach - Content
starts as a single column on small
screens and scales up
Bootstrap Containers
Container – It is used to pad the content
inside of them, and there are two container
classes available:
.container-fluid class
Grid Basics of Bootstrap
• Nesting Columns:
You can nest columns within
columns to create complex layouts.
Example
Create a two-column row within a
larger column.
Components of
Bootstrap
(1) Typography
<div class="btn-group">
<button type="button" class="btn btn-
primary">Apple</button>
<button type="button" class="btn btn-
primary">Samsung</button>
<button type="button" class="btn
btn-primary">Sony</button>
</div>
(7) Badges
• Badges are small, often colorful, elements used to add
information or notifications to content.
• Use the .badge class together with a contextual class (like .bg-
secondary) within <span> elements to create rectangular
badges.
Badge Colors
<div class="carousel-inner">
<div class="carousel-item active">
<img src=“apple.jpg" alt=“Apple" class="d-block w-100">
</div>
<div class="carousel-item">
<img src=“mango.jpg" alt=“Mango" class="d-block w-100">
</div>
<div class="carousel-item">
<img src=“banana.jpg" alt=“Banana" class="d-block w-100">
</div>
</div>
Captions to Slides
• Add elements inside <div class="carousel-
caption"> within each <div class="carousel-
item"> to create a caption for each slide
<div class="carousel-item">
<img src=“apple.jpg" alt=“Apple">
<div class="carousel-caption">
<h3>Apple</h3>
<p>Apple is a fruit which contains a lot of fiber.</p>
</div>
</div>
Navigation
• Bootstrap carousels come with navigation
controls for moving between slides.
• You can also add custom navigation buttons.
.slide Adds a CSS transition and animation effect when sliding from one item to
the next. Remove this class if you do not want this effect
Questions?
Thank you!