From 3f193f6745b9ec68cad703b4f43155b73c034bf3 Mon Sep 17 00:00:00 2001 From: Thalia Date: Thu, 3 Dec 2015 06:32:25 +0000 Subject: [PATCH] Make math dialog menu content scrollable Also make input widget height respond to its contents. These two changes address the problems of overlapping when the screen height is limited. Bug: T119900 Change-Id: Ie21c141673a9343d05da05cdbd2eaa96efff0a58 --- modules/ve-math/ve.ui.MWMathDialog.css | 1 + modules/ve-math/ve.ui.MWMathDialog.js | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/ve-math/ve.ui.MWMathDialog.css b/modules/ve-math/ve.ui.MWMathDialog.css index 00bbe1b..139d0e2 100644 --- a/modules/ve-math/ve.ui.MWMathDialog.css +++ b/modules/ve-math/ve.ui.MWMathDialog.css @@ -23,6 +23,7 @@ .ve-ui-mwMathDialog-menuLayout > .oo-ui-menuLayout-content { border-bottom: 1px solid #e6e6e6; box-shadow: 0 1px 0 0 rgba( 0, 0, 0, 0.05 ); + overflow: auto; } .ve-ui-mwMathPage-symbol { diff --git a/modules/ve-math/ve.ui.MWMathDialog.js b/modules/ve-math/ve.ui.MWMathDialog.js index 7d22f6c..7c42fea 100644 --- a/modules/ve-math/ve.ui.MWMathDialog.js +++ b/modules/ve-math/ve.ui.MWMathDialog.js @@ -101,7 +101,8 @@ ve.ui.MWMathDialog.prototype.initialize = function () { this.input = new ve.ui.MWAceEditorWidget( { multiline: true, - rows: 7, + autosize: true, + maxRows: 7, autocomplete: 'live' } ).setLanguage( 'latex' );