mahmoudbasha / minimalist

Automatically exported from code.google.com/p/minimalist
0 stars 0 forks source link

Event/calendar color replacement #192

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Please describe the feature or enhancement in as much detail as possible:

Original issue reported on code.google.com by anst...@gmail.com on 10 Feb 2012 at 4:21

GoogleCodeExporter commented 8 years ago
There is actually an easy way to do it with a little CSS hackery:

1. Figure out the hex code for the assigned color value of a given calendar. 
For example a single event looks something like this (emphasis mine):

<div class="ca-evp31 chip" style="top:525px;left:0%;width:100%;"> 
  <dl class="cbrd" style="height:32px;border-color:#23164E;background-color:#603F99;"> 
    <dt style="background-color:#23164E;">12:30p – 1:20p<i class="cic cic-tmr"> </i><i class="cic cic-spcl"> </i></dt> 
    <dd><span class="ca-elp31">M E 123 Midterm</span></dd> 
    <div class="resizer"><div class="rszr-icon"> </div></div> 
  </dl> 
</div>

2. Target all elements with the same background color as the DL and restyle 
them with the desired background and border colors:
dl[style *= "background-color:#603F99"] { background-color: #666666 !important; 
border-color: #333333 !important; }
Basically the bracketed selector targets all DL elements whose style attributes 
contain the string "background-color:#603F99". The "!important" suffix will 
ensure that that your styles will take precedent over the values given inline 
(by default, inline styles take precedence of all other styles)

3. Restyle the child DT with the desired background color and 
dl[style *= "background-color:#603F99"] dt { background-color: #333333 
!important; }

Original comment by anst...@gmail.com on 10 Feb 2012 at 4:27

GoogleCodeExporter commented 8 years ago
Nice-I saw this note and immediately donated $15.  If you implement a calendar 
fix for the low contrast events, I'll send more.

You have saved gmail for me. Thanks - Kael

Original comment by kael.fis...@gmail.com on 11 Feb 2012 at 7:17

GoogleCodeExporter commented 8 years ago
Google implemented this recently

Original comment by anst...@gmail.com on 23 Jan 2013 at 12:23