_carousel.scss 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. .carousel {
  2. &.carousel-slider {
  3. top: 0;
  4. left: 0;
  5. .carousel-fixed-item {
  6. &.with-indicators {
  7. bottom: 68px;
  8. }
  9. position: absolute;
  10. left: 0;
  11. right: 0;
  12. bottom: 20px;
  13. z-index: 1;
  14. }
  15. .carousel-item {
  16. width: 100%;
  17. height: 100%;
  18. min-height: $carousel-height;
  19. position: absolute;
  20. top: 0;
  21. left: 0;
  22. h2 {
  23. font-size: 24px;
  24. font-weight: 500;
  25. line-height: 32px;
  26. }
  27. p {
  28. font-size: 15px;
  29. }
  30. }
  31. }
  32. overflow: hidden;
  33. position: relative;
  34. width: 100%;
  35. height: $carousel-height;
  36. perspective: 500px;
  37. transform-style: preserve-3d;
  38. transform-origin: 0% 50%;
  39. .carousel-item {
  40. visibility: hidden;
  41. width: $carousel-item-width;
  42. height: $carousel-item-height;
  43. position: absolute;
  44. top: 0;
  45. left: 0;
  46. & > img {
  47. width: 100%;
  48. }
  49. }
  50. .indicators {
  51. position: absolute;
  52. text-align: center;
  53. left: 0;
  54. right: 0;
  55. bottom: 0;
  56. margin: 0;
  57. .indicator-item {
  58. &.active {
  59. background-color: #fff;
  60. }
  61. display: inline-block;
  62. position: relative;
  63. cursor: pointer;
  64. height: 8px;
  65. width: 8px;
  66. margin: 24px 4px;
  67. background-color: rgba(255,255,255,.5);
  68. transition: background-color .3s;
  69. border-radius: 50%;
  70. }
  71. }
  72. // Materialbox compatibility
  73. &.scrolling .carousel-item .materialboxed,
  74. .carousel-item:not(.active) .materialboxed {
  75. pointer-events: none;
  76. }
  77. }