_examples.scss 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. // Examples
  2. //
  3. // Styles for the Select2 examples, largely copied
  4. // from Bootstrap's docs styles.
  5. //
  6. // @see https://github.com/twbs/bootstrap/blob/master/docs/assets/css/src/docs.css#L533
  7. .s2-example {
  8. position: relative;
  9. padding: 45px 15px 15px;
  10. margin: 0 -15px 15px;
  11. background-color: #fafafa;
  12. box-shadow: inset 0 3px 6px rgba(0, 0, 0, 0.05);
  13. border-color: #e5e5e5 #eee #eee;
  14. border-style: solid;
  15. border-width: 1px 0;
  16. &:after {
  17. content: "Example";
  18. position: absolute;
  19. top: 15px;
  20. left: 15px;
  21. font-size: 12px;
  22. font-weight: bold;
  23. color: #bbb;
  24. text-transform: uppercase;
  25. letter-spacing: 1px;
  26. }
  27. @media (min-width: 768px) {
  28. margin-left: 0;
  29. margin-right: 0;
  30. background-color: #fff;
  31. border-width: 1px;
  32. border-color: #eee;
  33. border-radius: 4px 4px 0 0;
  34. box-shadow: none;
  35. }
  36. }
  37. // styles for the event log in the "DOM events" section of the docs
  38. .s2-event-log {
  39. background: #002451;
  40. color: white;
  41. font-family: Menlo, 'Bitstream Vera Sans Mono', 'DejaVu Sans Mono', Monaco, Consolas, monospace;
  42. margin: 0 -15px 15px;
  43. padding: 45px 15px 15px;
  44. position: relative;
  45. &:after {
  46. content: "Event Log";
  47. position: absolute;
  48. top: 15px;
  49. left: 15px;
  50. font-size: 12px;
  51. font-weight: bold;
  52. color: #BBB;
  53. text-transform: uppercase;
  54. letter-spacing: 1px;
  55. }
  56. @media (min-width: 768px) {
  57. margin-left: 0;
  58. margin-right: 0;
  59. margin-top: -15px;
  60. border-width: 1px;
  61. border-color: #eee;
  62. box-shadow: none;
  63. }
  64. }
  65. .s2-example + pre,
  66. .s2-event-log + pre {
  67. margin: -15px -15px 15px;
  68. border-radius: 0;
  69. border-width: 0 0 1px;
  70. @media (min-width: 768px) {
  71. margin-top: -16px;
  72. margin-left: 0;
  73. margin-right: 0;
  74. border-width: 1px;
  75. border-bottom-left-radius: 4px;
  76. border-bottom-right-radius: 4px;
  77. }
  78. }
  79. .s2-example + .s2-event-log {
  80. margin-top: -15px;
  81. }