I want to change the color of the current date in angular-material if that day is disabled since I have made a function that disables 2 days from now.
Example if today is 8-24-16 the datepicker disables 8-24-16 (today) and 8-25-16 (tomorrow), so I want to change the color that displays the current date if the date is disabled. Because when the current date disabled it shows the current date 8-24-16 (today) in a very light blue that is hard to see so I want to change that color to a different color that highlights more.
I tried looking at the css of angular-material but I couldn't find anything related to the css color of a disabled current date or a normal not disabled current date. I don't mind changing the color of both the normal current date and the disable current date. Also, my function that disabled the days sets the date from to days from now I don't know if this affects something.
Here is my code
<div class="form-group">
<label>Delivery Date:</label>
<md-datepicker ng-model="myDate" md-placeholder="Enter date"
md-max-date="maxDate"
md-min-date="minDate"
md-date-filter="disabledWeekends"
ng-disabled="disabled">
</md-datepicker>
</div>
My Controller
//adding two days
$scope.maxDate = new Date(
$scope.myDate.getFullYear(),
$scope.myDate.getMonth(),
$scope.myDate.getDate() + 2);
$scope.minDate = new Date(
$scope.myDate.getFullYear(),
$scope.myDate.getMonth(),
$scope.myDate.getDate() + 2);
$scope.myDate = $scope.minDate;
$scope.disabledWeekends = function (date) {
var day = date.getDay();
return day === 1 || day === 2 || day === 3
|| day === 4 || day === 5;
};
ctrl+shift+ithen select the element you want to change and check which css class is affecting it. - Gandalf the White