|
| 1 | +.accordion_view { |
| 2 | + display: flex; |
| 3 | + flex-direction: column; |
| 4 | + gap: space(2); |
| 5 | + min-height: 0; |
| 6 | + |
| 7 | + &-section { |
| 8 | + flex: none; |
| 9 | + display: flex; |
| 10 | + flex-direction: column; |
| 11 | + border: 1px solid var(--ui-on-surface-color-lighter); |
| 12 | + border-radius: rounded(); |
| 13 | + } |
| 14 | + |
| 15 | + &-section-fill { |
| 16 | + &[open], |
| 17 | + &.accordion_view-section-selected { |
| 18 | + flex: 1 1 auto; |
| 19 | + min-height: 0; |
| 20 | + } |
| 21 | + |
| 22 | + > .accordion_view-content { |
| 23 | + flex: 1 1 auto; |
| 24 | + } |
| 25 | + } |
| 26 | + |
| 27 | + &-section[open], |
| 28 | + &-section-selected { |
| 29 | + > .accordion_view-header { |
| 30 | + border-bottom: 1px solid var(--ui-on-surface-color-lightest); |
| 31 | + border-radius: rounded() rounded() 0 0; |
| 32 | + } |
| 33 | + } |
| 34 | + |
| 35 | + &-selectable_section > .accordion_view-header { |
| 36 | + background: var(--ui-secondary-surface-color); |
| 37 | + } |
| 38 | + |
| 39 | + &-section-selected > .accordion_view-header { |
| 40 | + background: var(--ui-selection-color-lighter); |
| 41 | + } |
| 42 | + |
| 43 | + &-section[open] > .accordion_view-summary::before { |
| 44 | + transform: rotate(0deg); |
| 45 | + } |
| 46 | + |
| 47 | + &-header { |
| 48 | + display: flex; |
| 49 | + align-items: flex-start; |
| 50 | + gap: space(2); |
| 51 | + margin: 0; |
| 52 | + padding: space(3) space(4); |
| 53 | + border-radius: rounded(); |
| 54 | + line-height: 20px; |
| 55 | + cursor: pointer; |
| 56 | + background: var(--ui-primary-color-lightest); |
| 57 | + |
| 58 | + input[type="radio"] { |
| 59 | + flex: none; |
| 60 | + width: 16px; |
| 61 | + height: 16px; |
| 62 | + margin: 2px 0 0; |
| 63 | + } |
| 64 | + } |
| 65 | + |
| 66 | + &-summary { |
| 67 | + list-style: none; |
| 68 | + |
| 69 | + &::-webkit-details-marker { |
| 70 | + display: none; |
| 71 | + } |
| 72 | + |
| 73 | + &::before { |
| 74 | + content: ""; |
| 75 | + flex: none; |
| 76 | + align-self: center; |
| 77 | + border-left: 5px solid transparent; |
| 78 | + border-right: 5px solid transparent; |
| 79 | + border-top: 6px solid var(--ui-on-surface-color-light); |
| 80 | + transform: rotate(-90deg); |
| 81 | + transition: transform 0.2s; |
| 82 | + } |
| 83 | + } |
| 84 | + |
| 85 | + &-header_text { |
| 86 | + display: flex; |
| 87 | + flex-direction: column; |
| 88 | + gap: space(1); |
| 89 | + } |
| 90 | + |
| 91 | + &-title { |
| 92 | + font-weight: 600; |
| 93 | + } |
| 94 | + |
| 95 | + &-description { |
| 96 | + color: var(--ui-on-surface-color-light); |
| 97 | + } |
| 98 | + |
| 99 | + &-content { |
| 100 | + display: flex; |
| 101 | + flex-direction: column; |
| 102 | + gap: space(3); |
| 103 | + padding: space(4); |
| 104 | + min-height: 0; |
| 105 | + color: var(--ui-on-surface-color); |
| 106 | + |
| 107 | + &[hidden] { |
| 108 | + display: none; |
| 109 | + } |
| 110 | + } |
| 111 | +} |
0 commit comments