index.html 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title>Buttons</title>
  6. <meta name="description" content="You can use button tag or also anchor tag with role button">
  7. <link rel="stylesheet" href="../buttons.css">
  8. <!--
  9. - This <style> and <link> is only used for the example preview,
  10. - it isn't needed for the real use case.
  11. -->
  12. <style>
  13. html, body {
  14. margin: 0;
  15. padding: 0;
  16. font-size: 10px;
  17. background-color: #fff;
  18. }
  19. h2.bb-docs {
  20. font-size: 1.8rem;
  21. font-weight: lighter;
  22. color: #666;
  23. margin: -0.1rem 0 0;
  24. background-color: #f5f5f5;
  25. padding: 0.4rem 0.4rem 0.4rem 3rem;
  26. border: solid 0.1rem #e8e8e8;
  27. }
  28. div.bb-docs {
  29. padding: 1rem;
  30. }
  31. div.bb-docs.dark {
  32. background: #000;
  33. }
  34. ul {
  35. padding: 0;
  36. margin: 0;
  37. list-style: none;
  38. }
  39. body[role="application"] > [role="region"] {
  40. height: 100%;
  41. position: relative;
  42. }
  43. </style>
  44. </head>
  45. <body role="application">
  46. <p dir="ltr">
  47. <label>
  48. <input type="checkbox"
  49. onchange="document.documentElement.dir = this.checked ? 'rtl' : 'ltr'">
  50. RTL mode
  51. </label>
  52. </p>
  53. <h2 class="bb-docs">Normal</h2>
  54. <div class="bb-docs">
  55. <button>Default</button>
  56. <button class="recommend">Recommend</button>
  57. <button class="danger">Danger</button>
  58. </div>
  59. <h2 class="bb-docs">Disabled</h2>
  60. <div class="bb-docs">
  61. <button disabled>Default</button>
  62. <a href="#" role="button" aria-disabled="true" class="recommend">Recommend</a>
  63. <button disabled class="danger">Danger</button>
  64. </div>
  65. <h2 class="bb-docs">Disabled with dark background</h2>
  66. <div class="bb-docs dark">
  67. <button disabled>Default</button>
  68. <a href="#" role="button" aria-disabled="true" class="recommend">Recommend</a>
  69. <button disabled class="danger">Danger</button>
  70. </div>
  71. <h2 class="bb-docs">Button List </h2>
  72. <div class="bb-docs">
  73. <ul>
  74. <li>
  75. <button>Default</button>
  76. </li>
  77. <li>
  78. <button disabled="disabled">Disabled</button>
  79. </li>
  80. <li>
  81. <button class="icon icon-view">
  82. View Name
  83. </button>
  84. </li>
  85. <li>
  86. <button disabled="disabled" class="icon icon-view">
  87. View Name
  88. </button>
  89. </li>
  90. <li>
  91. <a role="button" class="icon icon-dialog">
  92. Tuesday September 18, 2012
  93. </a>
  94. </li>
  95. <li>
  96. <a role="button" aria-disabled="true" class="icon icon-dialog">
  97. Tuesday September 18, 2012
  98. </a>
  99. </li>
  100. </ul>
  101. </div>
  102. <h2 class="bb-docs">Button list (compact mode)</h2>
  103. <div class="bb-docs">
  104. <ul class="compact">
  105. <li>
  106. <label>Description</label>
  107. <button class="icon icon-dialog">Action 1</button>
  108. </li>
  109. <li>
  110. <label>Description</label>
  111. <button class="icon icon-dialog">Action 2</button>
  112. </li>
  113. <li>
  114. <label>This is a large description for this action</label>
  115. <button class="icon icon-dialog" disabled >Action 3 (disabled)</button>
  116. </li>
  117. </ul>
  118. </div>
  119. </body>
  120. </html>