_message-list.scss
ASCII text
1/* Message List */ 2// a.k.a. notifications in the menu 3 4// main list 5.message-list { 6width: 31.5em; 7padding: 0; 8 9.message-list-placeholder { 10spacing: 12px; 11} 12} 13 14.message-list-sections { 15spacing: 8px; 16margin: 0 8px; // to account for scrollbar 17} 18 19.message-list-section, 20.message-list-section-list { 21spacing: 8px; 22} 23 24.message-list-section-list { 25&:ltr { 26padding-left: 0; 27} 28 29&:rtl { 30padding-right: 0; 31} 32} 33 34@if $version >= 3.36 { 35// do-not-disturb + clear button 36.message-list-controls { 37margin: 8px 8px 0; 38padding: 0; 39spacing: 8px; 40} 41} @else { 42// clear button 43.message-list-clear-button.button { 44@extend %button; 45margin: 8px 8px 0; 46} 47} 48 49// message bubbles 50.message { 51@extend %calendar-item; 52min-height: $menuitem-size * 2; 53 54// icon container 55.message-icon-bin { 56padding: 12px 0 12px 12px; 57 58&:rtl { 59padding: 12px 12px 12px 0; 60} 61 62// icon size and color 63> StIcon { 64-st-icon-style: requested; 65icon-size: 16px; 66color: inherit; 67 68&, 69&:rtl { 70margin: 0; 71} 72} 73 74// fallback 75> .fallback-app-icon { 76width: 16px; 77height: 16px; 78} 79} 80 81// content 82.message-content { 83min-height: $menuitem-size * 2 - 8px * 2; 84padding: 8px; 85spacing: 0; 86color: inherit; 87font-size: 1em; 88} 89 90// title 91.message-title { 92min-height: $small-size - 2px; 93padding-top: 2px; 94color: inherit; 95font-weight: bold; 96font-size: 1em; 97} 98 99// secondary container in title box 100.message-secondary-bin { 101padding: 0 8px; 102 103// notification time stamp 104> .event-time { 105min-height: $small-size - 2px; 106padding-top: 2px; 107color: hint($on-surface); 108font-size: 1em; 109text-align: right; 110 111// HACK: the label should be baseline-aligned with a 1em label, 112// fake this with some bottom padding 113padding-bottom: 0; 114 115&:ltr { 116text-align: right; 117} 118 119&:rtl { 120text-align: left; 121} 122} 123 124> StIcon { 125icon-size: 16px; 126} 127} 128 129// close button 130$message-close-button: if($version >= 3.36, ".message-close-button", ".message-content > StBoxLayout > StButton"); 131 132#{$message-close-button} { 133transition-duration: $duration; 134icon-size: 16px; 135padding: ($small-size - 16px) / 2; 136border-radius: $small-size / 2; 137 138&, 139&:hover, 140&:active { 141color: hint($on-surface); 142} 143 144&:focus { 145background-color: focus-overlay($on-surface); 146} 147 148&:hover { 149background-color: hover-overlay($on-surface); 150} 151 152&:active { 153transition-duration: $duration-ripple; 154background-color: pressed-overlay($on-surface); 155} 156} 157 158// body 159.message-body { 160color: hint($on-surface); 161} 162} 163 164// URLs in messages 165.url-highlighter { 166link-color: $primary; 167} 168 169/* Media Controls */ 170.message-media-control { 171transition-duration: $duration; 172margin: 16px 0; 173padding: 8px; 174border-radius: 16px; 175 176&, 177&:focus, 178&:hover, 179&:active { 180color: hint($on-surface); 181} 182 183&:focus { 184background-color: focus-overlay($on-surface); 185} 186 187&:hover { 188background-color: hover-overlay($on-surface); 189} 190 191&:active { 192background-color: pressed-overlay($on-surface); 193transition-duration: $duration-ripple; 194} 195 196&:insensitive { 197color: disabled-hint($on-surface); 198} 199 200&:last-child:ltr { 201margin-right: 16px; 202padding-right: 8px; 203border-radius: 16px; 204} 205 206&:last-child:rtl { 207margin-left: 16px; 208padding-left: 8px; 209border-radius: 16px; 210} 211} 212 213// album-art 214.media-message-cover-icon { 215icon-size: 32px !important; 216margin: 4px 0 !important; 217border-radius: 0; 218 219// when there is no artwork 220&.fallback { 221icon-size: 16px !important; 222padding: 8px; 223border: 0; 224border-radius: $corner-radius; 225background-color: fill($on-surface); 226color: disabled($on-surface) !important; 227} 228} 229