fix(textarea): firefox bug with disabled textarea drag

This commit is contained in:
jorenbroekema 2021-11-05 13:15:56 +01:00 committed by Thomas Allmer
parent eb61cbfed2
commit 5f3ef98ae9
2 changed files with 10 additions and 0 deletions

View file

@ -0,0 +1,5 @@
---
'@lion/textarea': patch
---
Temporary fix for a bug in FireFox where disabled textareas can crash the browser if dragged (resized).

View file

@ -157,6 +157,11 @@ export class LionTextarea extends NativeTextFieldMixin(LionFieldWithTextArea) {
.input-group__container > .input-group__input ::slotted(.form-control) {
overflow-x: hidden; /* for FF adds height to the TextArea to reserve place for scroll-bars */
}
/* Workaround https://bugzilla.mozilla.org/show_bug.cgi?id=1739079 */
:host([disabled]) ::slotted(textarea) {
user-select: none;
}
`,
];
}