|
5 | 5 | $max-width: var(--str-chat__attachment-max-width); |
6 | 6 |
|
7 | 7 | .str-chat__modal-gallery { |
8 | | - background: transparent; |
| 8 | + background-color: var(--chat-bg); |
9 | 9 | color: var(--str-chat__text-primary); |
10 | 10 | border-radius: calc( |
11 | 11 | var(--str-chat__message-bubble-radius-group-bottom) - var( |
|
17 | 17 | grid-template-rows: 50% 50%; |
18 | 18 | overflow: hidden; |
19 | 19 | border-radius: var(--str-chat__radius-lg); |
20 | | - gap: var(--str-chat__space-2); |
| 20 | + gap: var(--str-chat__spacing-xxs); |
21 | 21 | width: $max-width; |
22 | 22 | max-width: 100%; |
23 | 23 | aspect-ratio: 4 / 3; |
24 | 24 |
|
| 25 | + $outer-radius: var(--str-chat__radius-lg); |
| 26 | + $inner-radius: var(--str-chat__radius-md); |
| 27 | + |
25 | 28 | .str-chat__modal-gallery__image { |
26 | 29 | width: 100%; |
27 | 30 | height: 100%; |
28 | 31 | min-width: 0; |
29 | 32 | min-height: 0; |
| 33 | + border-radius: $inner-radius; |
| 34 | + |
| 35 | + &:nth-child(1) { |
| 36 | + border-start-start-radius: $outer-radius; |
| 37 | + } |
| 38 | + &:nth-child(2) { |
| 39 | + border-start-end-radius: $outer-radius; |
| 40 | + } |
| 41 | + &:nth-child(3) { |
| 42 | + border-end-start-radius: $outer-radius; |
| 43 | + } |
| 44 | + &:nth-child(4) { |
| 45 | + border-end-end-radius: $outer-radius; |
| 46 | + } |
30 | 47 | } |
31 | 48 |
|
32 | 49 | &.str-chat__modal-gallery--two-images { |
33 | 50 | grid-template-rows: 1fr; |
| 51 | + |
| 52 | + .str-chat__modal-gallery__image:nth-child(1) { |
| 53 | + border-end-start-radius: $outer-radius; |
| 54 | + } |
| 55 | + |
| 56 | + .str-chat__modal-gallery__image:nth-child(2) { |
| 57 | + border-end-end-radius: $outer-radius; |
| 58 | + } |
34 | 59 | } |
35 | 60 |
|
36 | 61 | &.str-chat__modal-gallery--three-images { |
37 | 62 | .str-chat__modal-gallery__image:nth-child(1) { |
38 | 63 | grid-column: 1; |
39 | | - grid-row: 1 / span 2; /* Span two rows */ |
| 64 | + grid-row: 1 / span 2; |
| 65 | + border-end-start-radius: $outer-radius; |
40 | 66 | } |
41 | 67 |
|
42 | 68 | .str-chat__modal-gallery__image:nth-child(2) { |
43 | 69 | grid-column: 2; |
44 | 70 | grid-row: 1; |
| 71 | + border-start-end-radius: $outer-radius; |
45 | 72 | } |
46 | 73 |
|
47 | 74 | .str-chat__modal-gallery__image:nth-child(3) { |
48 | 75 | grid-column: 2; |
49 | 76 | grid-row: 2; |
| 77 | + border-end-end-radius: $outer-radius; |
50 | 78 | } |
51 | 79 | } |
52 | 80 |
|
|
0 commit comments