Merge pull request #1356 from jschleic/multiplechoice-buttons-grid

switch to grid layout for multiple choice buttons
This commit is contained in:
Yohan Boniface 2023-10-04 09:42:47 +02:00 committed by GitHub
commit d0b01e774c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -342,19 +342,24 @@ input.switch:checked ~ label:before {
input.switch:checked ~ label:after {
margin-left: 3em;
}
.button-bar {
.button-bar, .umap-multiplechoice {
margin-top: 5px;
text-align: center;
display: grid;
grid-gap: 7px;
width: 100%
}
.button-bar {
grid-gap: 7px;
}
.button-bar.half {
grid-template-columns: 1fr 1fr;
}
.button-bar.third {
.umap-multiplechoice.by3 {
grid-template-columns: 1fr 1fr 1fr;
}
.umap-multiplechoice.by4 {
grid-template-columns: 1fr 1fr 1fr 1fr;
}
.button-bar .button {
display: inline-block;
}
@ -365,15 +370,12 @@ input.switch:checked ~ label:after {
border: 1px solid #374E75;
cursor: pointer;
background-color: #c9c9c7;
height: 30px;
min-height: 30px;
line-height: 30px;
text-align: center;
width: calc(100% / 3);
width: 100%;
display: inline-block;
}
.umap-multiplechoice.by4 label {
width: calc(100% / 4);
}
.dark .umap-multiplechoice label {
border: 1px solid black;
background-color: #2c3233;