From 7acec84f94d8dca616d9888eb284d586904daa83 Mon Sep 17 00:00:00 2001 From: James Ketrenos Date: Sat, 26 Feb 2022 15:44:39 -0800 Subject: [PATCH] Scale all dialogs to fit with scrolling Signed-off-by: James Ketrenos --- client/src/ChooseCard.css | 17 ++++++++++------- client/src/Table.css | 5 ++++- client/src/Trade.css | 17 ++++++++++------- client/src/ViewCard.css | 17 ++++++++++------- client/src/Winner.css | 19 ++++++++++++------- 5 files changed, 46 insertions(+), 29 deletions(-) diff --git a/client/src/ChooseCard.css b/client/src/ChooseCard.css index bec95e1..6c275ba 100644 --- a/client/src/ChooseCard.css +++ b/client/src/ChooseCard.css @@ -11,6 +11,16 @@ z-index: 1000; } +.ChooseCard > * { + max-height: calc(100vh - 2em); + overflow: auto; + margin: 0.5em; + width: 40em; + display: inline-flex; + padding: 0.5em; + flex-direction: column; +} + .ChooseCard .Title { align-self: center; padding: 2px; @@ -18,13 +28,6 @@ margin-bottom: 0.5em; } -.ChooseCard > * { -/* min-width: 40em;*/ - display: inline-flex; - padding: 0.5em; - flex-direction: column; -} - .ChooseCard .Stack { margin: 0; padding: 0; diff --git a/client/src/Table.css b/client/src/Table.css index 19d8564..e926d3b 100755 --- a/client/src/Table.css +++ b/client/src/Table.css @@ -2,7 +2,6 @@ display: flex; position: absolute; width: 100%; - overflow: hidden; height: 100%; justify-content: space-between; /* left-justify 'board', right-justify 'game' */ background-image: url("./assets/tabletop.png"); @@ -13,6 +12,8 @@ margin-right: 30rem; justify-content: space-between; align-items: flex-end; + height: 8rem; + overflow: visible; } .WaitingForPlayer { @@ -44,6 +45,8 @@ align-items: center; background: rgba(0,0,0,0.5); z-index: 1000; + max-height: 100vh; + overflow: auto; } .GameOrder .Title { diff --git a/client/src/Trade.css b/client/src/Trade.css index 2dd5bd7..1627ffd 100644 --- a/client/src/Trade.css +++ b/client/src/Trade.css @@ -11,6 +11,16 @@ z-index: 1000; } +.Trade > * { + max-height: calc(100vh - 2em); + overflow: auto; + width: 40em; + display: inline-flex; + padding: 0.5em; + flex-direction: column; + margin: 0.5em; +} + .Trade .Title { align-self: center; padding: 2px; @@ -23,13 +33,6 @@ margin: 0.5em 0; } -.Trade > * { - min-width: 40em; - display: inline-flex; - padding: 0.5em; - flex-direction: column; -} - .Trade .Resource { width: 3.75em; /* 5x7 aspect ratio */ height: 5.25em; diff --git a/client/src/ViewCard.css b/client/src/ViewCard.css index 00f31e0..71cecf7 100644 --- a/client/src/ViewCard.css +++ b/client/src/ViewCard.css @@ -11,6 +11,16 @@ z-index: 1000; } +.ViewCard > * { + max-height: calc(100vh - 2em); + overflow: auto; + margin: 0.5em; + width: 40em; + display: inline-flex; + padding: 0.5em; + flex-direction: column; +} + .ViewCard .Title { align-self: center; padding: 2px; @@ -24,13 +34,6 @@ box-sizing: border-box; } -.ViewCard > * { -/* min-width: 40em;*/ - display: inline-flex; - padding: 0.5em; - flex-direction: column; -} - .ViewCard .Resource { width: 10em; /* 5x7 aspect ratio */ height: 14em; diff --git a/client/src/Winner.css b/client/src/Winner.css index f6643cb..b5cebd7 100644 --- a/client/src/Winner.css +++ b/client/src/Winner.css @@ -9,6 +9,18 @@ align-items: center; background: rgba(0,0,0,0.5); z-index: 1000; + max-height: 100vh; + overflow: auto; +} + +.Winner > * { + max-height: calc(100vh - 2em); + overflow: auto; + margin: 0.5em; + width: 40em; + display: inline-flex; + padding: 0.5em; + flex-direction: column; } .Winner .Title { @@ -24,13 +36,6 @@ box-sizing: border-box; } -.Winner > * { -/* min-width: 40em;*/ - display: inline-flex; - padding: 0.5em; - flex-direction: column; -} - .Winner .Resource { width: 10em; /* 5x7 aspect ratio */ height: 14em;