carousel.scss 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. ---
  2. ---
  3. .carousel {
  4. width: 100%;
  5. overflow: hidden;
  6. .header {
  7. display: flex;
  8. flex-direction: row;
  9. margin-top: var(--margin);
  10. padding-top: var(--margin);
  11. padding-bottom: var(--margin);
  12. vertical-align: middle;
  13. animation-name: appear-from-blur;
  14. animation-duration: 1s;
  15. animation-fill-mode: forwards;
  16. h1 {
  17. margin-top: auto;
  18. margin-bottom: auto;
  19. font-size: x-large;
  20. font-weight: bold;
  21. }
  22. .arrow {
  23. position: relative;
  24. width: calc(var(--margin) + var(--button-icon-size));
  25. min-width: calc(var(--margin) + var(--button-icon-size));
  26. height: calc(var(--margin) + var(--button-icon-size));
  27. background: var(--color-container);
  28. border: none;
  29. border-radius: 50%;
  30. margin-right: var(--margin);
  31. padding: 0;
  32. & > img {
  33. width: 100%;
  34. height: 100%;
  35. filter: invert(100%);
  36. align-self: center;
  37. }
  38. }
  39. }
  40. #carousel-pane {
  41. position: relative;
  42. display: flex;
  43. flex-direction: row;
  44. left: calc(var(--margin) * -1);
  45. transition: transform .3s ease;
  46. transform: translateX(0);
  47. .card {
  48. position: relative;
  49. width: var(--product-card-width);
  50. max-width: calc(100% - var(--margin) * 2);
  51. display: flex;
  52. flex-direction: column;
  53. .icon {
  54. width: calc(var(--product-card-width));
  55. aspect-ratio: 1 / 1;
  56. border-radius: var(--corner-radius-small);
  57. margin-bottom: var(--margin);
  58. background-repeat: no-repeat;
  59. background-size: cover;
  60. background-position: center;
  61. }
  62. .name {
  63. font-size: large;
  64. font-weight: bold;
  65. white-space: nowrap;
  66. overflow: hidden;
  67. text-overflow: ellipsis;
  68. }
  69. .button {
  70. margin-top: auto;
  71. }
  72. #icon-container {
  73. display: flex;
  74. flex-direction: row;
  75. margin-top: auto;
  76. .source-badge {
  77. margin-right: var(--source-badge-margin);
  78. }
  79. }
  80. }
  81. }
  82. }