checkbox.html 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. ---
  2. title: Checkbox
  3. layout: documentation
  4. doc-tab: form
  5. doc-subtab: checkbox
  6. breadcrumb:
  7. - home
  8. - documentation
  9. - form
  10. - form-checkbox
  11. meta:
  12. colors: false
  13. sizes: false
  14. variables: false
  15. ---
  16. {% capture checkbox_example %}
  17. <label class="checkbox">
  18. <input type="checkbox">
  19. Remember me
  20. </label>
  21. {% endcapture %}
  22. {% capture checkbox_link_example %}
  23. <label class="checkbox">
  24. <input type="checkbox">
  25. I agree to the <a href="#">terms and conditions</a>
  26. </label>
  27. {% endcapture %}
  28. {% capture checkbox_disabled_example %}
  29. <label class="checkbox" disabled>
  30. <input type="checkbox" disabled>
  31. Save my preferences
  32. </label>
  33. {% endcapture %}
  34. <div class="content">
  35. <p>
  36. The <code>checkbox</code> class is a simple wrapper around the <code>&lt;input type="checkbox"&gt;</code> HTML element. It is intentionally not styled, to preserve cross-browser compatibility and the user experience.
  37. </p>
  38. </div>
  39. <div class="columns">
  40. <div class="column is-half">
  41. {{checkbox_example}}
  42. </div>
  43. <div class="column is-half highlight-full">
  44. {% highlight html %}{{checkbox_example}}{% endhighlight %}
  45. </div>
  46. </div>
  47. <div class="content">
  48. <p>
  49. You can add <strong>links</strong> to your checkbox, or even <strong>disable</strong> it.
  50. </p>
  51. </div>
  52. <div class="columns">
  53. <div class="column is-half">
  54. {{checkbox_link_example}}
  55. </div>
  56. <div class="column is-half highlight-full">
  57. {% highlight html %}{{checkbox_link_example}}{% endhighlight %}
  58. </div>
  59. </div>
  60. <div class="columns">
  61. <div class="column is-half">
  62. {{checkbox_disabled_example}}
  63. </div>
  64. <div class="column is-half highlight-full">
  65. {% highlight html %}{{checkbox_disabled_example}}{% endhighlight %}
  66. </div>
  67. </div>