bootstrap_styleguide 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (65) hide show
  1. checksums.yaml +7 -0
  2. data/MIT-LICENSE +20 -0
  3. data/README.md +31 -0
  4. data/Rakefile +18 -0
  5. data/app/assets/config/bootstrap_styleguide_manifest.js +1 -0
  6. data/app/assets/stylesheets/bootstrap_styleguide/application.css +15 -0
  7. data/app/controllers/bootstrap_styleguide/application_controller.rb +5 -0
  8. data/app/controllers/bootstrap_styleguide/components_controller.rb +5 -0
  9. data/app/controllers/bootstrap_styleguide/content_controller.rb +5 -0
  10. data/app/controllers/bootstrap_styleguide/forms_controller.rb +5 -0
  11. data/app/controllers/bootstrap_styleguide/layout_controller.rb +5 -0
  12. data/app/controllers/bootstrap_styleguide/styleguide_controller.rb +6 -0
  13. data/app/controllers/bootstrap_styleguide/utilities_controller.rb +5 -0
  14. data/app/helpers/bootstrap_styleguide/application_helper.rb +37 -0
  15. data/app/jobs/bootstrap_styleguide/application_job.rb +4 -0
  16. data/app/mailers/bootstrap_styleguide/application_mailer.rb +6 -0
  17. data/app/models/bootstrap_styleguide/application_record.rb +5 -0
  18. data/app/views/bootstrap_styleguide/components/accordion.html.erb +47 -0
  19. data/app/views/bootstrap_styleguide/components/alerts.html.erb +33 -0
  20. data/app/views/bootstrap_styleguide/components/badge.html.erb +41 -0
  21. data/app/views/bootstrap_styleguide/components/breadcrumbs.html.erb +42 -0
  22. data/app/views/bootstrap_styleguide/components/button_group.html.erb +67 -0
  23. data/app/views/bootstrap_styleguide/components/buttons.html.erb +43 -0
  24. data/app/views/bootstrap_styleguide/components/cards.html.erb +72 -0
  25. data/app/views/bootstrap_styleguide/components/carousel.html.erb +5 -0
  26. data/app/views/bootstrap_styleguide/components/close_button.html.erb +10 -0
  27. data/app/views/bootstrap_styleguide/components/collapse.html.erb +59 -0
  28. data/app/views/bootstrap_styleguide/components/dropdowns.html.erb +44 -0
  29. data/app/views/bootstrap_styleguide/components/modal.html.erb +63 -0
  30. data/app/views/bootstrap_styleguide/components/navbar.html.erb +44 -0
  31. data/app/views/bootstrap_styleguide/components/navs_and_tabs.html.erb +65 -0
  32. data/app/views/bootstrap_styleguide/components/offcanvas.html.erb +69 -0
  33. data/app/views/bootstrap_styleguide/components/pagination.html.erb +46 -0
  34. data/app/views/bootstrap_styleguide/components/popovers.html.erb +26 -0
  35. data/app/views/bootstrap_styleguide/components/progress.html.erb +61 -0
  36. data/app/views/bootstrap_styleguide/components/spinners.html.erb +62 -0
  37. data/app/views/bootstrap_styleguide/components/toasts.html.erb +58 -0
  38. data/app/views/bootstrap_styleguide/components/tooltips.html.erb +20 -0
  39. data/app/views/bootstrap_styleguide/content/images.html.erb +5 -0
  40. data/app/views/bootstrap_styleguide/content/tables.html.erb +74 -0
  41. data/app/views/bootstrap_styleguide/content/typography.html.erb +68 -0
  42. data/app/views/bootstrap_styleguide/forms/checks_and_radios.html.erb +58 -0
  43. data/app/views/bootstrap_styleguide/forms/floating_labels.html.erb +60 -0
  44. data/app/views/bootstrap_styleguide/forms/input_group.html.erb +30 -0
  45. data/app/views/bootstrap_styleguide/forms/range.html.erb +11 -0
  46. data/app/views/bootstrap_styleguide/forms/select.html.erb +34 -0
  47. data/app/views/bootstrap_styleguide/layout/breakpoints.html.erb +49 -0
  48. data/app/views/bootstrap_styleguide/layout/containers.html.erb +111 -0
  49. data/app/views/bootstrap_styleguide/layout/grid.html.erb +51 -0
  50. data/app/views/bootstrap_styleguide/styleguide/index.html.erb +24 -0
  51. data/app/views/bootstrap_styleguide/utilities/background.html.erb +38 -0
  52. data/app/views/bootstrap_styleguide/utilities/borders.html.erb +67 -0
  53. data/app/views/bootstrap_styleguide/utilities/colors.html.erb +26 -0
  54. data/app/views/bootstrap_styleguide/utilities/shadows.html.erb +13 -0
  55. data/app/views/bootstrap_styleguide/utilities/spacing.html.erb +37 -0
  56. data/app/views/bootstrap_styleguide/utilities/text.html.erb +25 -0
  57. data/app/views/layouts/_styleguide_header.html.erb +71 -0
  58. data/app/views/layouts/styleguide.html.erb +19 -0
  59. data/config/routes.rb +47 -0
  60. data/lib/bootstrap_styleguide/engine.rb +5 -0
  61. data/lib/bootstrap_styleguide/version.rb +3 -0
  62. data/lib/bootstrap_styleguide.rb +6 -0
  63. data/lib/generators/bootstrap_styleguide/install_generator.rb +22 -0
  64. data/lib/tasks/bootstrap_styleguide_tasks.rake +4 -0
  65. metadata +123 -0
@@ -0,0 +1,74 @@
1
+ <h1 id="content">Tables</h1>
2
+ <p>Documentation and examples for opt-in styling of tables (given their prevalent use in JavaScript plugins) with Bootstrap.</p>
3
+
4
+ <h2>Overview</h2>
5
+ <p>Due to the widespread use of <code>&lt;table&gt;</code> elements across third-party widgets like calendars and date pickers, Bootstrap’s tables are <strong>opt-in</strong>. Add the base class <code>.table</code> to any <code>&lt;table&gt;</code>, then extend with our optional modifier classes or custom styles. All table styles are not inherited in Bootstrap, meaning any nested tables can be styled independent from the parent.</p>
6
+
7
+ <p>Using the most basic table markup, here’s how <code>.table</code>-based tables look in Bootstrap.</p>
8
+
9
+ <%= example_with_code do %>
10
+ <table class="table">
11
+ <thead>
12
+ <tr>
13
+ <th scope="col">#</th>
14
+ <th scope="col">First</th>
15
+ <th scope="col">Last</th>
16
+ <th scope="col">Handle</th>
17
+ </tr>
18
+ </thead>
19
+ <tbody>
20
+ <tr>
21
+ <th scope="row">1</th>
22
+ <td>Mark</td>
23
+ <td>Otto</td>
24
+ <td>@mdo</td>
25
+ </tr>
26
+ <tr>
27
+ <th scope="row">2</th>
28
+ <td>Jacob</td>
29
+ <td>Thornton</td>
30
+ <td>@fat</td>
31
+ </tr>
32
+ <tr>
33
+ <th scope="row">3</th>
34
+ <td colspan="2">Larry the Bird</td>
35
+ <td>@twitter</td>
36
+ </tr>
37
+ </tbody>
38
+ </table>
39
+ <% end %>
40
+
41
+ <h2>Striped rows</h2>
42
+ <p>Use <code>.table-striped</code> to add zebra-striping to any table row within the <code>&lt;tbody&gt;</code>.</p>
43
+
44
+ <%= example_with_code do %>
45
+ <table class="table table-striped">
46
+ <thead>
47
+ <tr>
48
+ <th scope="col">#</th>
49
+ <th scope="col">First</th>
50
+ <th scope="col">Last</th>
51
+ <th scope="col">Handle</th>
52
+ </tr>
53
+ </thead>
54
+ <tbody>
55
+ <tr>
56
+ <th scope="row">1</th>
57
+ <td>Mark</td>
58
+ <td>Otto</td>
59
+ <td>@mdo</td>
60
+ </tr>
61
+ <tr>
62
+ <th scope="row">2</th>
63
+ <td>Jacob</td>
64
+ <td>Thornton</td>
65
+ <td>@fat</td>
66
+ </tr>
67
+ <tr>
68
+ <th scope="row">3</th>
69
+ <td colspan="2">Larry the Bird</td>
70
+ <td>@twitter</td>
71
+ </tr>
72
+ </tbody>
73
+ </table>
74
+ <% end %>
@@ -0,0 +1,68 @@
1
+ <h1 id="content">Typography</h1>
2
+ <p>Documentation and examples for Bootstrap typography, including global settings, headings, body text, lists, and more.</p>
3
+
4
+ <h2>Headings</h2>
5
+ <p>All HTML headings, <code>&lt;h1&gt;</code> through <code>&lt;h6&gt;</code>, are available.</p>
6
+
7
+ <table class="table">
8
+ <thead>
9
+ <tr>
10
+ <th>Heading</th>
11
+ <th>Example</th>
12
+ </tr>
13
+ </thead>
14
+ <tbody>
15
+ <tr>
16
+ <td>
17
+ <code>&lt;h1&gt;&lt;/h1&gt;</code>
18
+ </td>
19
+ <td><span class="h1">h1. Bootstrap heading</span></td>
20
+ </tr>
21
+ <tr>
22
+ <td>
23
+ <code>&lt;h2&gt;&lt;/h2&gt;</code>
24
+ </td>
25
+ <td><span class="h2">h2. Bootstrap heading</span></td>
26
+ </tr>
27
+ <tr>
28
+ <td>
29
+ <code>&lt;h3&gt;&lt;/h3&gt;</code>
30
+ </td>
31
+ <td><span class="h3">h3. Bootstrap heading</span></td>
32
+ </tr>
33
+ <tr>
34
+ <td>
35
+ <code>&lt;h4&gt;&lt;/h4&gt;</code>
36
+ </td>
37
+ <td><span class="h4">h4. Bootstrap heading</span></td>
38
+ </tr>
39
+ <tr>
40
+ <td>
41
+ <code>&lt;h5&gt;&lt;/h5&gt;</code>
42
+ </td>
43
+ <td><span class="h5">h5. Bootstrap heading</span></td>
44
+ </tr>
45
+ <tr>
46
+ <td>
47
+ <code>&lt;h6&gt;&lt;/h6&gt;</code>
48
+ </td>
49
+ <td><span class="h6">h6. Bootstrap heading</span></td>
50
+ </tr>
51
+ </tbody>
52
+ </table>
53
+
54
+ <h2>Inline text elements</h2>
55
+ <p>Styling for common inline HTML5 elements.</p>
56
+
57
+ <%= example_with_code do %>
58
+ <div class="bg-light p-3">
59
+ <p>You can use the mark tag to <mark>highlight</mark> text.</p>
60
+ <p><del>This line of text is meant to be treated as deleted text.</del></p>
61
+ <p><s>This line of text is meant to be treated as no longer accurate.</s></p>
62
+ <p><ins>This line of text is meant to be treated as an addition to the document.</ins></p>
63
+ <p><u>This line of text will render as underlined.</u></p>
64
+ <p><small>This line of text is meant to be treated as fine print.</small></p>
65
+ <p><strong>This line rendered as bold text.</strong></p>
66
+ <p><em>This line rendered as italicized text.</em></p>
67
+ </div>
68
+ <% end %>
@@ -0,0 +1,58 @@
1
+ <h1 id="content">Checks and radios</h1>
2
+ <p class="bd-lead">Create consistent cross-browser and cross-device checkboxes and radios with our completely rewritten checks component.</p>
3
+
4
+ <h2>Checks</h2>
5
+
6
+ <%= example_with_code do %>
7
+ <div class="form-check">
8
+ <input class="form-check-input" type="checkbox" value="" id="flexCheckDefault">
9
+ <label class="form-check-label" for="flexCheckDefault">
10
+ Default checkbox
11
+ </label>
12
+ </div>
13
+ <div class="form-check">
14
+ <input class="form-check-input" type="checkbox" value="" id="flexCheckChecked" checked>
15
+ <label class="form-check-label" for="flexCheckChecked">
16
+ Checked checkbox
17
+ </label>
18
+ </div>
19
+ <% end %>
20
+
21
+ <h2>Radios</h2>
22
+
23
+ <%= example_with_code do %>
24
+ <div class="form-check">
25
+ <input class="form-check-input" type="radio" name="flexRadioDefault" id="flexRadioDefault1">
26
+ <label class="form-check-label" for="flexRadioDefault1">
27
+ Default radio
28
+ </label>
29
+ </div>
30
+ <div class="form-check">
31
+ <input class="form-check-input" type="radio" name="flexRadioDefault" id="flexRadioDefault2" checked>
32
+ <label class="form-check-label" for="flexRadioDefault2">
33
+ Default checked radio
34
+ </label>
35
+ </div>
36
+ <% end %>
37
+
38
+ <h2 id="examples" class="mt-4">Radios</h2>
39
+ <p>A switch has the markup of a custom checkbox but uses the <code>.form-switch</code> class to render a toggle switch. Switches also support the <code>disabled</code> attribute.</p>
40
+
41
+ <%= example_with_code do %>
42
+ <div class="form-check form-switch">
43
+ <input class="form-check-input" type="checkbox" id="flexSwitchCheckDefault">
44
+ <label class="form-check-label" for="flexSwitchCheckDefault">Default switch checkbox input</label>
45
+ </div>
46
+ <div class="form-check form-switch">
47
+ <input class="form-check-input" type="checkbox" id="flexSwitchCheckChecked" checked>
48
+ <label class="form-check-label" for="flexSwitchCheckChecked">Checked switch checkbox input</label>
49
+ </div>
50
+ <div class="form-check form-switch">
51
+ <input class="form-check-input" type="checkbox" id="flexSwitchCheckDisabled" disabled>
52
+ <label class="form-check-label" for="flexSwitchCheckDisabled">Disabled switch checkbox input</label>
53
+ </div>
54
+ <div class="form-check form-switch">
55
+ <input class="form-check-input" type="checkbox" id="flexSwitchCheckCheckedDisabled" checked disabled>
56
+ <label class="form-check-label" for="flexSwitchCheckCheckedDisabled">Disabled checked switch checkbox input</label>
57
+ </div>
58
+ <% end %>
@@ -0,0 +1,60 @@
1
+ <h1 id="content">Floating labels</h1>
2
+ <p class="bd-lead">Create beautifully simple form labels that float over your input fields.</p>
3
+
4
+ <h2>Example</h2>
5
+ <p>Wrap a pair of <code>&lt;input class="form-control"&gt;</code> and <code>&lt;label&gt;</code> elements in <code>.form-floating</code> to enable floating labels with Bootstrap’s textual form fields. A <code>placeholder</code> is required on each <code>&lt;input&gt;</code> as our method of CSS-only floating labels uses the <code>:placeholder-shown</code> pseudo-element. Also note that the <code>&lt;input&gt;</code> must come first so we can utilize a sibling selector (e.g., <code>~</code>).</p>
6
+
7
+ <%= example_with_code do %>
8
+ <div class="form-floating mb-3">
9
+ <input type="email" class="form-control" id="floatingInput" placeholder="name@example.com">
10
+ <label for="floatingInput">Email address</label>
11
+ </div>
12
+ <div class="form-floating">
13
+ <input type="password" class="form-control" id="floatingPassword" placeholder="Password">
14
+ <label for="floatingPassword">Password</label>
15
+ </div>
16
+ <% end %>
17
+
18
+ <p>When there’s a <code>value</code> already defined, <code>&lt;label&gt;</code>s will automatically adjust to their floated position.</p>
19
+
20
+ <%= example_with_code do %>
21
+ <form class="form-floating">
22
+ <input type="email" class="form-control" id="floatingInputValue" placeholder="name@example.com" value="test@example.com">
23
+ <label for="floatingInputValue">Input with value</label>
24
+ </form>
25
+ <% end %>
26
+
27
+ <p>Form validation styles also work as expected.</p>
28
+
29
+ <%= example_with_code do %>
30
+ <form class="form-floating">
31
+ <input type="email" class="form-control is-invalid" id="floatingInputInvalid" placeholder="name@example.com" value="test@example.com">
32
+ <label for="floatingInputInvalid">Invalid input</label>
33
+ </form>
34
+ <% end %>
35
+
36
+ <h2>Textareas</h2>
37
+ <p>By default, <code>&lt;textarea&gt;</code>s with <code>.form-control</code> will be the same height as <code>&lt;input&gt;</code>s.</p>
38
+
39
+ <%= example_with_code do %>
40
+ <div class="form-floating">
41
+ <textarea class="form-control" placeholder="Leave a comment here" id="floatingTextarea"></textarea>
42
+ <label for="floatingTextarea">Comments</label>
43
+ </div>
44
+ <% end %>
45
+
46
+ <h2>Textareas</h2>
47
+
48
+ <p>Other than <code>.form-control</code>, floating labels are only available on <code>.form-select</code>s. They work in the same way, but unlike <code>&lt;input&gt;</code>s, they’ll always show the <code>&lt;label&gt;</code> in its floated state. <strong>Selects with <code>size</code> and <code>multiple</code> are not supported.</strong></p>
49
+
50
+ <%= example_with_code do %>
51
+ <div class="form-floating">
52
+ <select class="form-select" id="floatingSelect" aria-label="Floating label select example">
53
+ <option selected>Open this select menu</option>
54
+ <option value="1">One</option>
55
+ <option value="2">Two</option>
56
+ <option value="3">Three</option>
57
+ </select>
58
+ <label for="floatingSelect">Works with selects</label>
59
+ </div>
60
+ <% end %>
@@ -0,0 +1,30 @@
1
+ <h1 id="content">Input group</h1>
2
+ <p class="bd-lead">Give textual form controls like <code>&lt;input&gt;</code>s and <code>&lt;textarea&gt;</code>s an upgrade with custom styles, sizing, focus states, and more.</p>
3
+
4
+ <h2>Examples</h2>
5
+
6
+ <%= example_with_code do %>
7
+ <div class="mb-3">
8
+ <label for="exampleFormControlInput1" class="form-label">Email address</label>
9
+ <input type="email" class="form-control" id="exampleFormControlInput1" placeholder="name@example.com">
10
+ </div>
11
+ <div class="mb-3">
12
+ <label for="exampleFormControlTextarea1" class="form-label">Example textarea</label>
13
+ <textarea class="form-control" id="exampleFormControlTextarea1" rows="3"></textarea>
14
+ </div>
15
+ <% end %>
16
+
17
+ <h2>Sizing</h2>
18
+ <p>Set heights using classes like <code>.form-control-lg</code> and <code>.form-control-sm</code>.</p>
19
+
20
+ <%= example_with_code do %>
21
+ <div class="mb-3">
22
+ <input class="form-control form-control-lg" type="text" placeholder=".form-control-lg" aria-label=".form-control-lg example">
23
+ </div>
24
+ <div class="mb-3">
25
+ <input class="form-control" type="text" placeholder="Default input" aria-label="default input example">
26
+ </div>
27
+ <div class="mb-3">
28
+ <input class="form-control form-control-sm" type="text" placeholder=".form-control-sm" aria-label=".form-control-sm example">
29
+ </div>
30
+ <% end %>
@@ -0,0 +1,11 @@
1
+ <h1 id="content">Range</h1>
2
+ <p class="bd-lead">Use our custom range inputs for consistent cross-browser styling and built-in customization.</p>
3
+
4
+ <h2>Overview</h2>
5
+
6
+ <p>Create custom <code>&lt;input type="range"&gt;</code> controls with <code>.form-range</code>. The track (the background) and thumb (the value) are both styled to appear the same across browsers. As only Firefox supports “filling” their track from the left or right of the thumb as a means to visually indicate progress, we do not currently support it.</p>
7
+
8
+ <%= example_with_code do %>
9
+ <label for="customRange1" class="form-label">Example range</label>
10
+ <input type="range" class="form-range" id="customRange1">
11
+ <% end %>
@@ -0,0 +1,34 @@
1
+ <h1 id="content">Select</h1>
2
+ <p>Customize the native <code>&lt;select&gt;</code>s with custom CSS that changes the element’s initial appearance.</p>
3
+
4
+ <h2>Default</h2>
5
+
6
+ <p>Custom <code>&lt;select&gt;</code> menus need only a custom class, <code>.form-select</code> to trigger the custom styles. Custom styles are limited to the <code>&lt;select&gt;</code>’s initial appearance and cannot modify the <code>&lt;option&gt;</code>s due to browser limitations.</p>
7
+
8
+ <% example_with_code do %>
9
+ <select class="form-select" aria-label="Default select example">
10
+ <option selected>Open this select menu</option>
11
+ <option value="1">One</option>
12
+ <option value="2">Two</option>
13
+ <option value="3">Three</option>
14
+ </select>
15
+ <% end %>
16
+
17
+ <h2>Sizing</h2>
18
+ <p>You may also choose from small and large custom selects to match our similarly sized text inputs.</p>
19
+
20
+ <% example_with_code do %>
21
+ <select class="form-select form-select-lg mb-3" aria-label=".form-select-lg example">
22
+ <option selected>Open this select menu</option>
23
+ <option value="1">One</option>
24
+ <option value="2">Two</option>
25
+ <option value="3">Three</option>
26
+ </select>
27
+
28
+ <select class="form-select form-select-sm" aria-label=".form-select-sm example">
29
+ <option selected>Open this select menu</option>
30
+ <option value="1">One</option>
31
+ <option value="2">Two</option>
32
+ <option value="3">Three</option>
33
+ </select>
34
+ <% end %>
@@ -0,0 +1,49 @@
1
+ <h1 id="content">Breakpoints</h1>
2
+ <p>Breakpoints are customizable widths that determine how your responsive layout behaves across device or viewport sizes in Bootstrap.</p>
3
+
4
+ <h2>Available breakpoints</h2>
5
+ <p>Bootstrap includes six default breakpoints, sometimes referred to as grid tiers, for building responsively. These breakpoints can be customized if you’re using our source Sass files.</p>
6
+
7
+ <table class="table">
8
+ <thead>
9
+ <tr>
10
+ <th>Breakpoint</th>
11
+ <th>Class infix</th>
12
+ <th>Dimensions</th>
13
+ </tr>
14
+ </thead>
15
+ <tbody>
16
+ <tr>
17
+ <td>X-Small</td>
18
+ <td><em>None</em></td>
19
+ <td>&lt;576px</td>
20
+ </tr>
21
+ <tr>
22
+ <td>Small</td>
23
+ <td><code>sm</code></td>
24
+ <td>≥576px</td>
25
+ </tr>
26
+ <tr>
27
+ <td>Medium</td>
28
+ <td><code>md</code></td>
29
+ <td>≥768px</td>
30
+ </tr>
31
+ <tr>
32
+ <td>Large</td>
33
+ <td><code>lg</code></td>
34
+ <td>≥992px</td>
35
+ </tr>
36
+ <tr>
37
+ <td>Extra large</td>
38
+ <td><code>xl</code></td>
39
+ <td>≥1200px</td>
40
+ </tr>
41
+ <tr>
42
+ <td>Extra extra large</td>
43
+ <td><code>xxl</code></td>
44
+ <td>≥1400px</td>
45
+ </tr>
46
+ </tbody>
47
+ </table>
48
+
49
+ <p>These breakpoints are customizable via Sass—you’ll find them in a Sass map in our _variables.scss stylesheet.</p>
@@ -0,0 +1,111 @@
1
+ <h1 id="content">Containers</h1>
2
+ <p>Containers are a fundamental building block of Bootstrap that contain, pad, and align your content within a given device or viewport.</p>
3
+
4
+ <h2>How they work</h2>
5
+ <p>Containers are the most basic layout element in Bootstrap and are <strong>required when using our default grid system</strong>. Containers are used to contain, pad, and (sometimes) center the content within them. While containers <em>can</em> be nested, most layouts do not require a nested container.</p>
6
+ <p>Bootstrap comes with three different containers:</p>
7
+
8
+ <ul>
9
+ <li><code>.container</code>, which sets a <code>max-width</code> at each responsive breakpoint</li>
10
+ <li><code>.container-fluid</code>, which is <code>width: 100%</code> at all breakpoints</li>
11
+ <li><code>.container-{breakpoint}</code>, which is <code>width: 100%</code> until the specified breakpoint</li>
12
+ </ul>
13
+
14
+ <p>The table below illustrates how each container’s <code>max-width</code> compares to the original <code>.container</code> and <code>.container-fluid</code> across each breakpoint.</p>
15
+
16
+ <table class="table">
17
+ <thead>
18
+ <tr>
19
+ <td class="border-dark"></td>
20
+ <th scope="col">
21
+ Extra small<br>
22
+ <span class="fw-normal">&lt;576px</span>
23
+ </th>
24
+ <th scope="col">
25
+ Small<br>
26
+ <span class="fw-normal">≥576px</span>
27
+ </th>
28
+ <th scope="col">
29
+ Medium<br>
30
+ <span class="fw-normal">≥768px</span>
31
+ </th>
32
+ <th scope="col">
33
+ Large<br>
34
+ <span class="fw-normal">≥992px</span>
35
+ </th>
36
+ <th scope="col">
37
+ X-Large<br>
38
+ <span class="fw-normal">≥1200px</span>
39
+ </th>
40
+ <th scope="col">
41
+ XX-Large<br>
42
+ <span class="fw-normal">≥1400px</span>
43
+ </th>
44
+ </tr>
45
+ </thead>
46
+ <tbody>
47
+ <tr>
48
+ <th scope="row" class="fw-normal"><code>.container</code></th>
49
+ <td class="text-muted">100%</td>
50
+ <td>540px</td>
51
+ <td>720px</td>
52
+ <td>960px</td>
53
+ <td>1140px</td>
54
+ <td>1320px</td>
55
+ </tr>
56
+ <tr>
57
+ <th scope="row" class="fw-normal"><code>.container-sm</code></th>
58
+ <td class="text-muted">100%</td>
59
+ <td>540px</td>
60
+ <td>720px</td>
61
+ <td>960px</td>
62
+ <td>1140px</td>
63
+ <td>1320px</td>
64
+ </tr>
65
+ <tr>
66
+ <th scope="row" class="fw-normal"><code>.container-md</code></th>
67
+ <td class="text-muted">100%</td>
68
+ <td class="text-muted">100%</td>
69
+ <td>720px</td>
70
+ <td>960px</td>
71
+ <td>1140px</td>
72
+ <td>1320px</td>
73
+ </tr>
74
+ <tr>
75
+ <th scope="row" class="fw-normal"><code>.container-lg</code></th>
76
+ <td class="text-muted">100%</td>
77
+ <td class="text-muted">100%</td>
78
+ <td class="text-muted">100%</td>
79
+ <td>960px</td>
80
+ <td>1140px</td>
81
+ <td>1320px</td>
82
+ </tr>
83
+ <tr>
84
+ <th scope="row" class="fw-normal"><code>.container-xl</code></th>
85
+ <td class="text-muted">100%</td>
86
+ <td class="text-muted">100%</td>
87
+ <td class="text-muted">100%</td>
88
+ <td class="text-muted">100%</td>
89
+ <td>1140px</td>
90
+ <td>1320px</td>
91
+ </tr>
92
+ <tr>
93
+ <th scope="row" class="fw-normal"><code>.container-xxl</code></th>
94
+ <td class="text-muted">100%</td>
95
+ <td class="text-muted">100%</td>
96
+ <td class="text-muted">100%</td>
97
+ <td class="text-muted">100%</td>
98
+ <td class="text-muted">100%</td>
99
+ <td>1320px</td>
100
+ </tr>
101
+ <tr>
102
+ <th scope="row" class="fw-normal"><code>.container-fluid</code></th>
103
+ <td class="text-muted">100%</td>
104
+ <td class="text-muted">100%</td>
105
+ <td class="text-muted">100%</td>
106
+ <td class="text-muted">100%</td>
107
+ <td class="text-muted">100%</td>
108
+ <td class="text-muted">100%</td>
109
+ </tr>
110
+ </tbody>
111
+ </table>
@@ -0,0 +1,51 @@
1
+ <h1 id="content">Grid system</h1>
2
+ <p>Use our powerful mobile-first flexbox grid to build layouts of all shapes and sizes thanks to a twelve column system, six default responsive tiers, Sass variables and mixins, and dozens of predefined classes.</p>
3
+
4
+ <h2>Example</h2>
5
+ <p>Bootstrap’s grid system uses a series of containers, rows, and columns to layout and align content. It’s built with flexbox and is fully responsive. Below is an example and an in-depth explanation for how the grid system comes together.</p>
6
+
7
+ <%= example_with_code do %>
8
+ <div class="container bg-light">
9
+ <div class="row">
10
+ <div class="col py-3 border">
11
+ Column
12
+ </div>
13
+ <div class="col py-3 border">
14
+ Column
15
+ </div>
16
+ <div class="col py-3 border">
17
+ Column
18
+ </div>
19
+ </div>
20
+ </div>
21
+ <% end %>
22
+
23
+ <h2>Variable width content</h2>
24
+ <p>Use <code>col-{breakpoint}-auto</code> classes to size columns based on the natural width of their content.</p>
25
+
26
+ <%= example_with_code do %>
27
+ <div class="container p-2">
28
+ <div class="row justify-content-md-center">
29
+ <div class="col col-lg-2 bg-light py-3 border">
30
+ 1 of 3
31
+ </div>
32
+ <div class="col-md-auto bg-light py-3 border">
33
+ Variable width content
34
+ </div>
35
+ <div class="col col-lg-2 bg-light py-3 border">
36
+ 3 of 3
37
+ </div>
38
+ </div>
39
+ <div class="row mt-3">
40
+ <div class="col bg-light py-3 border">
41
+ 1 of 3
42
+ </div>
43
+ <div class="col-md-auto bg-light py-3 border">
44
+ Variable width content
45
+ </div>
46
+ <div class="col col-lg-2 bg-light py-3 border">
47
+ 3 of 3
48
+ </div>
49
+ </div>
50
+ </div>
51
+ <% end %>
@@ -0,0 +1,24 @@
1
+ <h2>Layout</h2>
2
+ <% layout_items.each do |item| %>
3
+ <%= link_to item.to_s.humanize, send("layout_#{item}_path"), class: 'btn btn-primary mb-2' %>
4
+ <% end %>
5
+
6
+ <h2 class="mt-3">Content</h2>
7
+ <% content_items.each do |item| %>
8
+ <%= link_to item.to_s.humanize, send("content_#{item}_path"), class: 'btn btn-primary mb-2' %>
9
+ <% end %>
10
+
11
+ <h2 class="mt-3">Forms</h2>
12
+ <% forms_items.each do |item| %>
13
+ <%= link_to item.to_s.humanize, send("forms_#{item}_path"), class: 'btn btn-primary mb-2' %>
14
+ <% end %>
15
+
16
+ <h2 class="mt-3">Components</h2>
17
+ <% components_items.each do |item| %>
18
+ <%= link_to item.to_s.humanize, send("components_#{item}_path"), class: 'btn btn-primary mb-2' %>
19
+ <% end %>
20
+
21
+ <h2 class="mt-3">Utilities</h2>
22
+ <% utilities_items.each do |item| %>
23
+ <%= link_to item.to_s.humanize, send("utilities_#{item}_path"), class: 'btn btn-primary mb-2' %>
24
+ <% end %>
@@ -0,0 +1,38 @@
1
+ <h1 id="content">Background</h1>
2
+ <p class="bd-lead">Convey meaning through <code>background-color</code> and add decoration with gradients.</p>
3
+
4
+ <h2>Background color</h2>
5
+
6
+ <p>Similar to the contextual text color classes, set the background of an element to any contextual class. Background utilities <strong>do not set <code>color</code></strong>, so in some cases you’ll want to use <code>.text-*</code>.</p>
7
+
8
+ <%= example_with_code do %>
9
+ <div class="p-3 mb-2 bg-primary text-white">.bg-primary</div>
10
+ <div class="p-3 mb-2 bg-secondary text-white">.bg-secondary</div>
11
+ <div class="p-3 mb-2 bg-success text-white">.bg-success</div>
12
+ <div class="p-3 mb-2 bg-danger text-white">.bg-danger</div>
13
+ <div class="p-3 mb-2 bg-warning text-dark">.bg-warning</div>
14
+ <div class="p-3 mb-2 bg-info text-dark">.bg-info</div>
15
+ <div class="p-3 mb-2 bg-light text-dark">.bg-light</div>
16
+ <div class="p-3 mb-2 bg-dark text-white">.bg-dark</div>
17
+ <div class="p-3 mb-2 bg-body text-dark">.bg-body</div>
18
+ <div class="p-3 mb-2 bg-white text-dark">.bg-white</div>
19
+ <div class="p-3 mb-2 bg-transparent text-dark">.bg-transparent</div>
20
+ <% end %>
21
+
22
+ <h2>Background gradient</h2>
23
+
24
+ <p>By adding a <code>.bg-gradient</code> class, a linear gradient is added as background image to the backgrounds. This gradient starts with a semi-transparent white which fades out to the bottom.</p>
25
+
26
+ <%= example_with_code do %>
27
+ <div class="p-3 mb-2 bg-primary bg-gradient text-white">.bg-primary</div>
28
+ <div class="p-3 mb-2 bg-secondary bg-gradient text-white">.bg-secondary</div>
29
+ <div class="p-3 mb-2 bg-success bg-gradient text-white">.bg-success</div>
30
+ <div class="p-3 mb-2 bg-danger bg-gradient text-white">.bg-danger</div>
31
+ <div class="p-3 mb-2 bg-warning bg-gradient text-dark">.bg-warning</div>
32
+ <div class="p-3 mb-2 bg-info bg-gradient text-dark">.bg-info</div>
33
+ <div class="p-3 mb-2 bg-light bg-gradient text-dark">.bg-light</div>
34
+ <div class="p-3 mb-2 bg-dark bg-gradient text-white">.bg-dark</div>
35
+ <div class="p-3 mb-2 bg-body bg-gradient text-dark">.bg-body</div>
36
+ <div class="p-3 mb-2 bg-white bg-gradient text-dark">.bg-white</div>
37
+ <div class="p-3 mb-2 bg-transparent bg-gradient text-dark">.bg-transparent</div>
38
+ <% end %>