Center buttons and make them full width on tiny screens

This commit is contained in:
Andre Perunicic 2022-09-25 01:47:04 -04:00
parent 428d262796
commit ba95dc47cd
2 changed files with 16 additions and 1 deletions

View file

@ -43,7 +43,7 @@ class RepeatView extends ItemView {
this.root = this.containerEl.children[1];
this.messageContainer = this.root.createEl('div', { cls: 'repeat-message' });
this.buttonsContainer = this.root.createDiv();
this.buttonsContainer = this.root.createEl('div', { cls: 'repeat-buttons' });
this.previewContainer = this.root.createEl('div', { cls: 'repeat-embedded_note' });
this.indexPromise = new Promise((resolve, reject) => {
if (!this.dv) {

View file

@ -2,6 +2,21 @@
text-align: center;
}
.repeat-buttons {
text-align: center;
}
.repeat-buttons > button {
margin-top: 15px;
}
/* Make buttons legible on mobile. */
@media (max-width: 450px) {
.repeat-buttons > button {
width: 100%;
}
}
.repeat-embedded_note {
padding: 15px 30px;
}