Tweak tgui modals to self-resize and support \n

This commit is contained in:
Aronai Sieyes
2021-06-26 10:39:56 -04:00
parent 4c12504e3b
commit 9186827e87
3 changed files with 5 additions and 1 deletions
+3 -1
View File
@@ -65,11 +65,13 @@ export class AlertModal extends Component {
const { current } = this.state;
const focusCurrentButton = () => this.setCurrent(current, false);
const windowHeight = Math.max(150, message.length);
return (
<Window
title={title}
width={350}
height={150}
height={windowHeight}
canClose={timeout > 0}>
{timeout && <Loader value={timeout} />}
<Window.Content
@@ -8,6 +8,7 @@
.AlertModal__Message {
text-align: center;
justify-content: center;
white-space: pre-line;
}
.AlertModal__Buttons {
@@ -13,6 +13,7 @@
.ListInput__Section .Section__titleText {
font-size: base.em(12px);
white-space: pre-line;
}
.ListInput__Loader {