Containers
</>Extra small <768px
|
Small ≥768px
|
Medium ≥992px
|
Large ≥1200px
|
|
---|---|---|---|---|
container |
100% - 30px | 750px | 970px | 1170px |
container-fluid |
100% - 30px | 100% - 30px | 100% - 30px | 100% - 30px |
Row
</>Column
</>Align any content centered middle
</>Form Control
Basic form
Input Colors (Label + Input)
</>Textarea form-group form-control
Select list dropdown
</>Badges and Labels
Badge
btn > badge
panel > badge
Labels
Default labels
Button Style
Transparent buttons
Block button
Button group (btn-group)
Table
Table Color
Firstname | Lastname | |
---|---|---|
Default | Defaultson | [email protected] |
<tr class="success"> <td>Success</td> </tr> | Doe | [email protected] |
<tr class="danger"> <td>danger</td> </tr> | Moe | [email protected] |
<tr class="info"> <td>info</td> </tr> | Dooley | [email protected] |
<tr class="warning"> <td>warning</td> </tr> | Refs | [email protected] |
<tr class="active"> <td>table data</td> </tr> | Activeson | [email protected] |
table table-bordered table-striped table-hover
# | Firstname |
---|---|
1 | Anna |
2 | Debbie |
3 | John |
4 | Mehedi |
5 | Riad |
# | Firstname |
---|---|
1 | Anna |
2 | Debbie |
3 | John |
4 | Mehedi |
5 | Riad |
# | Firstname |
---|---|
1 | Anna |
2 | Debbie |
3 | John |
4 | Mehedi |
5 | Riad |
# | Firstname |
---|---|
1 | Anna |
2 | Debbie |
3 | John |
4 | Mehedi |
5 | Riad |
# | Firstname |
---|---|
1 | Anna |
2 | Debbie |
3 | John |
4 | Mehedi |
5 | Riad |
panel > panel-group
Card
Card with top image
card-title
card-text Lorem ipsum, dolor sit amet consectetur adipisicing elit. Aut, voluptatum.
btn btn-primaryCard with bottom image
Card title
This is a wider card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Last updated 3 mins ago
Card with Header and Footer
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhereImage overlays
Horizontal Card
Card title
This is a wider card with supporting text below as a natural lead-in to additional content. This content is a little bit longer.
Last updated 3 mins ago
Featured card
Featured
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhereBackground and color
Primary card title
Some quick example text to build on the card title and make up the bulk of the card's content.
secondary card title
Some quick example text to build on the card title and make up the bulk of the card's content.
success card title
Some quick example text to build on the card title and make up the bulk of the card's content.
danger card title
Some quick example text to build on the card title and make up the bulk of the card's content.
warning card title
Some quick example text to build on the card title and make up the bulk of the card's content.
info card title
Some quick example text to build on the card title and make up the bulk of the card's content.
light card title
Some quick example text to build on the card title and make up the bulk of the card's content.
dark card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Border and text
Primary card title
Some quick example text to build on the card title and make up the bulk of the card's content.
secondary card title
Some quick example text to build on the card title and make up the bulk of the card's content.
success card title
Some quick example text to build on the card title and make up the bulk of the card's content.
danger card title
Some quick example text to build on the card title and make up the bulk of the card's content.
warning card title
Some quick example text to build on the card title and make up the bulk of the card's content.
info card title
Some quick example text to build on the card title and make up the bulk of the card's content.
light card title
Some quick example text to build on the card title and make up the bulk of the card's content.
dark card title
Some quick example text to build on the card title and make up the bulk of the card's content.
Card Group
Card title
Lorem ipsum dolor sit amet consectetur, adipisicing elit. Natus quaerat praesentium eligendi vitae. Ex, sed!
Card title
Lorem ipsum dolor, sit amet consectetur adipisicing elit. Dignissimos odit vero quos necessitatibus! Enim, iure totam. Ea similique, explicabo officia doloribus voluptatibus numquam iure eius illo omnis quas doloremque deserunt quasi! Sapiente.
Card title
Lorem ipsum dolor sit amet.
Card with Nav tab
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhereMenu 1
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
Menu 2
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.
Card with Nav pill
Special title treatment
With supporting text below as a natural lead-in to additional content.
Go somewhereMenu 1
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
Menu 2
Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.
Card with Quote
A well-known quote, contained in a blockquote element.
Collapse (Accordion)
Lorem ipsum, dolor sit amet consectetur adipisicing elit. Dicta perspiciatis illum vero temporibus, odit omnis maiores sed quidem iure dolore aliquid explicabo distinctio nam excepturi voluptas facere quae tempore. Alias, distinctio cumque?
Collapsible Card Group
Collapsible Panel Group
Alert
Alert Links
Dropdown
Modal
Welcome to observer area
<div id="" class="" observer="true" funcName="" onHideFuncName=""></div>
observer="true"
andthis function for visible element
funcName=""
& this function for invisible element
onHideFuncName=""
CSS Flex
Media table | ||||
---|---|---|---|---|
xs | sm | md | lg | xxl |
<767px | ≥768 | ≥992 | ≥1200 | ≥1400 |
Enable flex behaviors
Justify content
justify-content-
or align-items / content
also working with
media xs / sm / md / lg and xxl
Align items
Align self
Flex Fill
Flex Grow
Fkex Shrink
Flex Direction
d-flex flex-row-reverse
Flex Direction
d-flex flex-row
d-flex flex-column
d-flex flex-column-reverse
Utilities Spacing
Margin and padding
Assign responsive-friendly margin
or padding
values to an
element or a subset of its
sides with shorthand classes.
Notation
Spacing utilities that apply to all breakpoints, from xs
to
lg
and bonus feature is
xxl
also
The classes are named using the format {property}{sides}-{size}
for
xs
and
{property}{sides}-{breakpoint}-{size}
for xs
,
sm
,
md
, lg
,
and bonus xxl
.
Where property is one of:
m
- for classes that setmargin
p
- for classes that setpadding
Where sides is one of:
t
- for classes that setmargin-top
orpadding-top
b
- for classes that setmargin-bottom
orpadding-bottom
s
- (start) for classes that setmargin-left
orpadding-left
in LTR,margin-right
orpadding-right
in RTLe
- (end) for classes that setmargin-right
orpadding-right
in LTR,margin-left
orpadding-left
in RTLx
- for classes that set both*-left
and*-right
y
- for classes that set both*-top
and*-bottom
- blank - for classes that set a
margin
orpadding
on all 4 sides of the element
Where size is one of:
0
- for classes that eliminate themargin
orpadding
by setting it to0
1
- (by default) for classes that set themargin
orpadding
to1px
2
- (by default) for classes that set themargin
orpadding
to2px
3
- (by default) for classes that set themargin
orpadding
to3px
4
- (by default) for classes that set themargin
orpadding
to4px
5
- (by default) for classes that set themargin
orpadding
to5px
6
- (by default) for classes that set themargin
orpadding
to6px
7
- (by default) for classes that set themargin
orpadding
to7px
8
- (by default) for classes that set themargin
orpadding
to8px
9
- (by default) for classes that set themargin
orpadding
to9px
10
- (by default) for classes that set themargin
orpadding
to10px
15
- (by default) for classes that set themargin
orpadding
to15px
20
- (by default) for classes that set themargin
orpadding
to20px
25
- (by default) for classes that set themargin
orpadding
to25px
50
- (by default) for classes that set themargin
orpadding
to50px
auto
- for classes that set themargin
toauto
Examples
Here are some representative examples of these classes:
.mt-0 {
margin-top: 0px;
}
.ml-0, .ms-0 {
margin-left: 0px;
}
.mb-0 {
margin-bottom: 0px;
}
.mr-0, .me-0 {
margin-right: 0px;
}
.mx-0 {
margin-inline: 0px;
}
.my-0 {
margin-block: 0px;
}
.m-auto {
margin: auto;
}
Horizontal centering
Additionally, osl-css-framework also includes an .mx-auto
class for
horizontally
centering fixed-width block
level content—that is, content that has display: block
and a
width
set—by setting the
horizontal margins to auto
.
Verticallly centering
Additionally, osl-css-framework also includes an .my-auto
class for
Verticallly
centering fixed-height block
level content
Utilities Position
This utilities for Position relative / absolute / fixed / sticky etc
set position using class:
position-relative
orrelative
for position: relativeposition-absolute
orabsolute
for position: absoluteposition-absolute-auto
orabsolute-auto
orposition-absolute-middle
orabsolute-middle
for position: middle on relative contentposition-fixed
orfixed
for position: fixedposition-static
orstatic
for position: staticposition-sticky
orsticky
for position: stickyposition-inherit
for position: inheritposition-unset
for position: unset
Where sides is one of:
t
ortop
- for classes that settop
b
orbottom
- for classes that setbottom
s/l
orstart/left
- for classes that setleft
e/r
orend/right
- for classes that setright
- for classes that setright
----- new
inset-0
for classes that set top + right + bottom + left 0pxinset-x-0
orinset-block-0
- for classes that set both*-left
and*-right
0inset-y-0
orinset-inline-0
- for classes that set both*-top
and*-bottom
0
Where size is one of:
0
- for classes that eliminate the above/below by setting it to0px
1
- (by default) for classes that set the1px
2
- (by default) for classes that set the2px
3
- (by default) for classes that set the3px
4
- (by default) for classes that set the4px
5
- (by default) for classes that set the5px
6
- (by default) for classes that set the6px
7
- (by default) for classes that set the7px
8
- (by default) for classes that set the8px
9
- (by default) for classes that set the9px
10
- (by default) for classes that set the10px
15
- (by default) for classes that set the15px
20
- (by default) for classes that set the20px
25
- (by default) for classes that set the25px
50
- (by default) for classes that set the50px
auto
- for classes that set theauto
Utilities Font weight and style
This utilities for font-weight and font-style
set font weight using class:
fw-bold
orfont-bold
for font-weight: boldfw-bolder
orfont-bolder
for font-weight: bolderfw-lighter
orfont-lighter
for font-weight: lighterfw-100
orfont-100
for font-weight: 100fw-200
orfont-200
for font-weight: 200fw-300
orfont-300
orfw-light
orfont-light
for font-weight: 300fw-400
orfont-400
orfw-normal
orfont-normal
for font-weight: 400fw-500
orfont-500
for font-weight: 500fw-600
orfont-600
for font-weight: 600fw-700
orfont-700
for font-weight: 700fw-800
orfont-800
for font-weight: 800fw-900
orfont-900
for font-weight: 900fw-950
orfont-950
for font-weight: 950fst-italic
orfont-italic
orfont-style-italic
for font-style: italicfst-normal
orfont-style-normal
for font-style: normal
Utilities Font size
font-size increase using parent font-size
fs-1
= parentFontSize *1
; }fs-1_1
= parentFontSize *1.1
; }fs-1_2
= parentFontSize *1.2
; }fs-1_3
= parentFontSize *1.3
; }fs-1_4
= parentFontSize *1.4
; }fs-1_5
= parentFontSize *1.5
; }fs-1_6
= parentFontSize *1.6
; }fs-1_7
= parentFontSize *1.7
; }fs-1_8
= parentFontSize *1.8
; }fs-1_9
= parentFontSize *1.9
; }fs-2
= parentFontSize *2
; }fs-2_5
= parentFontSize *2.5
; }fs-3
= parentFontSize *3
; }fs-3_5
= parentFontSize *3.5
; }fs-4
= parentFontSize *4
; }fs-4_5
= parentFontSize *4.5
; }fs-5
= parentFontSize *5
; }fs-5_5
= parentFontSize *5.5
; }fs-6
= parentFontSize *6
; }fs-6_5
= parentFontSize *6.5
; }
Utilities Color
This utilities for set background / text color
set text and background both using class:
- text-bg-primary
- text-bg-secondary
- text-bg-success
- text-bg-danger
- text-bg-warning / text-bg-warn
- text-bg-info
- text-bg-light
- text-bg-dark
set background color using class:
- bg-light / bg-white
- bg-primary
- bg-secondary
- bg-disabled
- bg-success
- bg-danger
- bg-warning / bg-warn
- bg-info
- bg-dark text-light
- bg-transparent border
set text color using class:
- text-primary
- text-secondary
- text-success
- text-danger
- text-warning
- text-info
- bg-dark text-light
- text-dark
Utilities Show / Hide / visible / invisible
This utilities for show and hide
hide / hidden
for classes that set the display: none;show
for classes that set the display: block;invisible
for classes that set the visibility: hidden;affix
for classes that set the position: fixed; with z-index: 1029;
Utilities Table Cell Align
The vertical-align CSS property sets vertical alignment of an inline, inline-block or table-cell box.
align-baseline | align-top | align-middle | align-bottom |
text-left | text-start | text-right | text-end |
text-justify Lorem ipsum, dolor sit amet consectetur adipisicing elit. Exercitationem, reiciendis! | text-center |
top: ⭐ middle: ⭐ bottom: ⭐ super: ⭐ sub: ⭐ text-top: ⭐ text-bottom: ⭐
Section Scroll
Customize your scrollbar
Use class customScrollbar
assign Variables for customize :
scrollbar size --scroll-thumb-color: #ff000051;
scrollbar color --scroll-size: 10px;
Scroll X set width
--scrollX-width: 100%;
Scroll Y set height
--scrollY-height: 500px
Scroll Both set height and width
--scrollBoth-height: 500px;
--scrollBoth-width: 100%;
Text Selection
user-select-all
user-select-auto
user-select-none
Border
border-0
border-top-0
border-end-0
border-right-0
border-bottom-0
border-start-0
border-left-0
JavaScript Global Variables, It's update with event lister
-
isScrollTop
→ It's returntrue / false
after scroll -
checkImageUrl('https://****.com')
→ It's returntrue / false
after check. async func -
getDomainFromUrl('https://****.com')
→ It's returndomain name
-
copyContent('copy target', 'type', 'successMessageTarget element')
↓ more detailsCopy contentExample 1: String pass #ID or .ClassName with hash '#' / dot '.'
copyContent('#demoTarget', 'text', #successMessageTarget); copyContent('.demoTarget', 'html', .successMessageTarget);
Example 2: JavaScript
const demoTarget = document.querySelector('#demoTarget'); copyContent(demoTarget); const demoTarget2 = document.querySelector('.demoTarget2'); copyContent(demoTarget2);
Example 3: jQuery
copyContent($('#demoTarget')); copyContent($('.demoTarget'));
-
getRandomHexColor()
→ It's return random hex color code as"#198754"
Reload color