By Josh Lewis on Saturday, 29 November 2014
Posted in General Issues
Likes 0
Views 701
Votes 0
There appears to be no easy way to change the background color of stream item icons due to there not being a class around the span tag that wraps the icons based on the stream type. Right now stream icons use the classes "stream-icon pull-right ml-5".



When attempting to change the background, it does this for all of the stream icons which end up making all of the icons feel the same. So what I recommend is adding classes to the span tags based on their activity type. So for example for an article it could have the classes "stream-icon pull-right ml-5 es-article" which would not harm the display and allow us to change the styling. This would also allow for the icons to natively be styled through CSS instead of inline.
Each stream item wrapper contains a "unique" class based on it's type. You can alter the color of the icons by using css selectors. Example:


.type-users .stream-icon {
background: #000 !important;
}


There is nothing impossible with CSS, it just depends on how creative you can be playing around with selectors
·
Sunday, 30 November 2014 00:59
·
0 Likes
·
0 Votes
·
0 Comments
·
I forgot to check the "li" element that wraps the entire stream object. I checked the div just before it but figured further up in the DOM set it wouldn't have a selector with a unique class. I know I could have done something like:

.stream-icon[style*="#fccd1b"]


I try to use attribute selectors sparingly for browser support, especially mobile phones. I think I knew about the li items having unique classes before my head injury (I made a post about this a while back). The good news is that my CSS knowledge is still doing well. Thanks Mark for the reply.
·
Sunday, 30 November 2014 03:43
·
0 Likes
·
0 Votes
·
0 Comments
·
No problem Josh
·
Sunday, 30 November 2014 12:27
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post