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

Material icon doesn't show #7948

Closed
leihuagh opened this issue Oct 22, 2017 · 8 comments
Closed

Material icon doesn't show #7948

leihuagh opened this issue Oct 22, 2017 · 8 comments

Comments

@leihuagh
Copy link

Bug, feature request, or proposal:

Bug

What is the expected behavior?

It should work

What is the current behavior?

Result: Material icon doesn't show on button, on card, on anywhere

What are the steps to reproduce?

Step by step followed the https://material.angular.io/guide/getting-started

What is the use-case or motivation for changing an existing behavior?

First time try

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Angular 5.0.0-rc.3
Material: 2.0.0-beta.12
OS: Windows 10
Typescript: 2.5.3
Browsers: Google Chrome

Is there anything else we should know?

I imported hammerjs. I linked the google material+icon to index.html

@EdricChan03
Copy link
Contributor

Show your full code please.

@leihuagh
Copy link
Author

@leihuagh
Copy link
Author

leihuagh commented Oct 22, 2017 via email

@EdricChan03
Copy link
Contributor

EdricChan03 commented Oct 22, 2017

That's because you're missing the CSS stylesheet for Material Icons!

Add the following to your index.html:

<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">

Around here:
https://github.com/leihuagh/MEAN-Project-Learning/blob/ba731ca72d98e1eaaf9bb0067c130184979de035/client/src/index.html#L6-L8

@ghd8
Copy link

ghd8 commented Oct 22, 2017

@leihuagh - Import of MatIconModule is missing. (in "app-material.module.ts")

For troubleshooting / questions please use stack overflow, gitter, etc.

@leihuagh
Copy link
Author

@ghd8 Thank you so much. The MatIconModule was missing in my material list

It works now.

@Chan4077 Thank you too

It could be nice to have entire material package in one in the future releases.

@mandaputtra
Copy link

Hello, i found this issue not working on IOS. I tried to use mat-error on IOS and its not showing, the code i use :

  <div class="error-container" *ngIf="dataerror">
    <div class="error-content">
      <div class="error-icon">
        <mat-icon color="warn">warning</mat-icon>
      </div>
      <div class="error-label">
        <span>{{errordesc}}</span>
      </div>
    </div>
  </div>

I also attach the stylesheet on index html.

icot added a commit to cerndb/dbod-web that referenced this issue Dec 17, 2018
icot added a commit to cerndb/dbod-web that referenced this issue Dec 17, 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 9, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants