Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change color of datetimepicker toggle #4934

Closed
aminebizid opened this issue Jun 2, 2017 · 5 comments · Fixed by #5317
Closed

Change color of datetimepicker toggle #4934

aminebizid opened this issue Jun 2, 2017 · 5 comments · Fixed by #5317
Assignees
Labels
P2 The issue is important to a large percentage of users, with a workaround

Comments

@aminebizid
Copy link

feature request:

I would like to change the color of the datetime picker toggle. The default color is black and i see i'ts an image and not a font.

What is the expected behavior?

Add an attribute [toggleColor]="Primary"
<md-datepicker #dateStart startView="year" [startAt]="start" [toggleColor]="Primary"></md-datepicker>

@willshowell
Copy link
Contributor

Related, you can't make it gray when disabled... I've been having to set the opacity instead

.mat-datepicker-toggle[disabled] {
  opacity: 0.38;
}

@jelbourn jelbourn added discussion feature This issue represents a new feature or feature request rather than a bug or bug fix labels Jun 2, 2017
@michaelz
Copy link

This makes it sadly unusable with a dark theme.

@mmalerba mmalerba added P2 The issue is important to a large percentage of users, with a workaround and removed discussion feature This issue represents a new feature or feature request rather than a bug or bug fix labels Jun 21, 2017
@mmalerba
Copy link
Contributor

Yes, this is definitely a problem... trying to figure out the best way to fix.

@michaelz In the mean time if you need to work with dark theme I recommend just don't use the toggle. Use an md-icon and hook up the click handler manually. Sorry for the inconvenience

@jorgenfb
Copy link

My current workaround is to inline the image in a :

  <md-input-container>
    <input mdInput [mdDatepicker]="myDatepicker" formControlName="time">
    <button md-icon-button mdSuffix (click)="myDatepicker.opened ? myDatepicker.close() : myDatepicker.open()">
      <md-icon><svg xmlns="http://www.w3.org/2000/svg" width="24px" height="24px" viewBox="0 0 24 24" fill="currentColor"><path d="M0 0h24v24H0z" fill="none"/><path d="M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z"/></svg></md-icon>
    </button>
  </md-input-container>
  <md-datepicker #myDatepicker></md-datepicker>

@angular angular deleted a comment from torabian Dec 1, 2018
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
P2 The issue is important to a large percentage of users, with a workaround
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants