Answers for "bootstrap 4 stateful buttons"

39

bootstarp btn colors

<button type="button" class="btn btn-primary">Blue</button>
<button type="button" class="btn btn-secondary">Grey</button>
<button type="button" class="btn btn-success">Green</button>
<button type="button" class="btn btn-danger">Red</button>
<button type="button" class="btn btn-warning">Yellow</button>
<button type="button" class="btn btn-info">Ligth blue</button>
<button type="button" class="btn btn-light">White</button>
<button type="button" class="btn btn-dark">Black</button>

<button type="button" class="btn btn-link">White with blue text</button>
Posted by: Guest on April-23-2020
19

bootstrap Buttons

Bootstrap includes several predefined button styles, each serving its own
semantic purpose, with a few extras thrown in for more control.
Using color to add meaning only provides a visual indication, which will
not be conveyed to users of assistive technologies – such as screen readers. 
Ensure that information denoted by the color is either obvious from the 
content itself (e.g. the visible text), or is included through alternative
means, such as additional text hidden with the .sr-only class.

<button type="button" class="btn btn-primary">Primary</button>
<button type="button" class="btn btn-secondary">Secondary</button>
<button type="button" class="btn btn-success">Success</button>
<button type="button" class="btn btn-danger">Danger</button>
<button type="button" class="btn btn-warning">Warning</button>
<button type="button" class="btn btn-info">Info</button>
<button type="button" class="btn btn-light">Light</button>
<button type="button" class="btn btn-dark">Dark</button>

<button type="button" class="btn btn-link">Link</button>
Posted by: Guest on October-23-2020
0

bootstrap button group

<!-- Basic example -->
<div class="btn-group" role="group" aria-label="Basic example">
   <button type="button" class="btn btn-primary">Left</button>
   <button type="button" class="btn btn-primary">Middle</button>
   <button type="button" class="btn btn-primary">Right</button>
</div>

<!-- Outlined styles -->
<div class="btn-group" role="group" aria-label="Basic outlined example">
   <button type="button" class="btn btn-outline-primary">Left</button>
   <button type="button" class="btn btn-outline-primary">Middle</button>
   <button type="button" class="btn btn-outline-primary">Right</button>
</div>

<!-- Checkbox and radio button groups -->
<div
   class="btn-group"
   role="group"
   aria-label="Basic checkbox toggle button group"
>
   <input type="checkbox" class="btn-check" id="btncheck1" autocomplete="off" />
   <label class="btn btn-outline-primary" for="btncheck1">Checkbox 1</label>

   <input type="checkbox" class="btn-check" id="btncheck2" autocomplete="off" />
   <label class="btn btn-outline-primary" for="btncheck2">Checkbox 2</label>

   <input type="checkbox" class="btn-check" id="btncheck3" autocomplete="off" />
   <label class="btn btn-outline-primary" for="btncheck3">Checkbox 3</label>
</div>

<!-- Button toolbar -->
<div class="btn-toolbar" role="toolbar" aria-label="Toolbar with button groups">
   <div class="btn-group me-2" role="group" aria-label="First group">
      <button type="button" class="btn btn-primary">1</button>
      <button type="button" class="btn btn-primary">2</button>
      <button type="button" class="btn btn-primary">3</button>
      <button type="button" class="btn btn-primary">4</button>
   </div>
   <div class="btn-group me-2" role="group" aria-label="Second group">
      <button type="button" class="btn btn-secondary">5</button>
      <button type="button" class="btn btn-secondary">6</button>
      <button type="button" class="btn btn-secondary">7</button>
   </div>
   <div class="btn-group" role="group" aria-label="Third group">
      <button type="button" class="btn btn-info">8</button>
   </div>
</div>
Posted by: Guest on March-01-2021

Browse Popular Code Answers by Language