Skip to content

Commit 6aaddbf

Browse files
crisbetoandrewseguin
authored andcommitted
fix(input): IE always adding scrollbar to textarea (#4917)
* Fixes IE always adding a scrollbar to Material textareas, even if they don't overflow. * Removes a double theme toggle from the demo app. It was probably the result of a bad merge.
1 parent 7f298f7 commit 6aaddbf

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

Diff for: src/demo-app/demo-app/demo-app.html

-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
<div class="demo-toolbar">
2727
<h1>Angular Material Demos</h1>
2828
<div>
29-
<button md-button (click)="dark = !dark">{{dark ? 'Light' : 'Dark'}} theme</button>
3029
<button md-button (click)="toggleChangeDetection()" title="Toggle change detection">
3130
Change detection: {{changeDetectionStrategy}}
3231
</button>

Diff for: src/lib/input/input-container.scss

+5
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,11 @@ $mat-input-underline-height: 1px !default;
143143
pointer-events: none; // We shouldn't catch mouse events (let them through).
144144
}
145145

146+
// Prevents IE from always adding a scrollbar by default.
147+
textarea.mat-input-element {
148+
overflow: auto;
149+
}
150+
146151
// The placeholder label. This is invisible unless it is. The logic to show it is
147152
// basically `empty || (float && (!empty || focused))`. Float is dependent on the
148153
// `floatingPlaceholder` input.

0 commit comments

Comments
 (0)