Skip to content
This repository has been archived by the owner on Jun 16, 2019. It is now read-only.

mdl-select broken layout #1059

Open
andream16 opened this issue Sep 20, 2017 · 1 comment
Open

mdl-select broken layout #1059

andream16 opened this issue Sep 20, 2017 · 1 comment

Comments

@andream16
Copy link

andream16 commented Sep 20, 2017

I'm reporting this issue since I'm using mdl-select and I can't understand why I get this layout:

Closed mdl-select:
1

Notice the misplaced dropdown image and the visible white line under it.

Opened mdl-select:
2

No onhover effect and still misplaced icon.

HTML:

<mdl-select placeholder="{{coutryLabel}}" floating-label="floating-label" [(ngModel)]="otherCountryCode">
    <mdl-option *ngFor="let c of countries" [value]="c.code">{{c.name}}</mdl-option>
 </mdl-select>

TS:

public coutryLabel = 'Italy';
public countries = [
    { name : 'France', code : 0 },
    { name : 'Germany', code : 1 }
];

Imported import { MdlSelectModule } from '@angular-mdl/select'; inside module where this component has been declared.

package.json:

"dependencies": {
    "@angular-mdl/core": "4.0.8",
    "@angular-mdl/popover": "^0.8.0",
    "@angular-mdl/select": "^0.11.1",
    "@angular/core": "4.3.6",
    . . . 
},
"devDependencies": {
    "@angular/cli": "1.1.0",
    "@angular/compiler-cli": "4.3.6",
    . . . 
}
@stephen-wigginton
Copy link

stephen-wigginton commented Oct 5, 2017

did you import the styles into one of your css/sass files? I dumped mine at the top of my app.component.scss, when i had this issue, and all was good afterwards.
you would just add the following, @andream16
@import '~@angular-mdl/select/select';

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

2 participants