"Ribbon Buttons"
Bootstrap 3.3.0 Snippet by AtiqUrRehman

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<!------ Include the above in your HEAD tag ---------->
<div class="container">
<div class="row">
<h2>Bootstrap Ribbon Buttons</h2>
</div>
<div class="row">
<div class="col-md-6"> <!-- Standard button -->
<button type="button" class="btn btn-default ribbon">Default</button>
<!-- Provides extra visual weight and identifies the primary action in a set of buttons -->
<button type="button" class="btn btn-primary ribbon">Primary</button>
<!-- Indicates a successful or positive action -->
<button type="button" class="btn btn-success ribbon">Success</button>
<!-- Contextual button for informational alert messages -->
<button type="button" class="btn btn-info ribbon">Info</button>
<!-- Indicates caution should be taken with this action -->
<button type="button" class="btn btn-warning ribbon">Warning</button>
<!-- Indicates a dangerous or potentially negative action -->
<button type="button" class="btn btn-danger ribbon">Danger</button>
<!-- Deemphasize a button by making it look like a link while maintaining button behavior -->
</div>
<div class="col-md-3 "> <!-- Standard button -->
<button type="button" class="btn btn-default ribbon">Default</button>
<!-- Provides extra visual weight and identifies the primary action in a set of buttons -->
<button type="button" class="btn btn-primary ribbon">Primary</button>
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
/*Remove that CSS*/
.col-md-3 {
margin-left:5%;
}
/*Remove that CSS*/
button {
margin: 20px 0;
line-height: 34px;
position: relative;
cursor: pointer;
user-select: none;
outline:none !important;
width:100%;
}
button:active {
outline:none;
}
button.ribbon {
outline:none;
outline-color: transparent;
}
button.ribbon:before, button.ribbon:after {
top: 5px;
z-index: -10;
}
button.ribbon:before {
border-color: #53dab6 #53dab6 #53dab6 transparent;
left: -25px;
border-width: 17px;
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
1
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Related: See More


Questions / Comments: