[Misc] Redesign the guest warning dialog (#882)

This commit is contained in:
Cinder 2025-02-03 08:28:19 -08:00 committed by GitHub
parent fe4f51b82b
commit c3e0dd6588
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 44 additions and 31 deletions

View File

@ -59,14 +59,6 @@
}
}
.guest-warning {
.guest-warning-dialog {
top: 5vh;
height: 90vh;
width: 80vw;
}
}
div#page {
> div /* div#c-$controller */

View File

@ -1,33 +1,55 @@
.guest-warning {
position: fixed;
left: 0;
top: 0;
height: 100vh;
width: 100vw;
z-index: 500;
background-color: themed("color-background");
left: 0;
right: 0;
bottom: 0;
z-index: 1000;
display: flex;
justify-content: center;
background: themed("color-background");
.guest-warning-dialog {
z-index: 500;
position: relative;
top: 20vh;
margin-left: auto;
margin-right: auto;
height: 40vh;
width: 40vw;
overflow-x: scroll;
background-color: themed("color-section");
margin: 20vh 0.5em 0;
height: min-content;
max-width: 360px;
.dialog-header {
padding: $padding-050 $base-padding;
background-color: themed("color-section-lighten-5");
border-bottom: 1px solid themed("color-background");
padding: 0 0.5em;
margin-bottom: 0.5em;
}
.dialog-content {
padding: $padding-050 $base-padding;
background: var(--color-foreground);
padding: 2em 1em 1em;
border-radius: 3px 3px 0 0;
p:last-child { margin-bottom: 0; }
}
.dialog-footer {
padding: $padding-050 $base-padding;
display: flex;
flex-wrap: wrap;
gap: 0.5em;
background: var(--color-foreground);
padding: 1em 1em 2em;
border-radius: 0 0 3px 3px;
button {
background: var(--color-section-lighten-5);
color: var(--color-link);
padding: 0.5em 1em;
border-radius: 3px;
&:hover {
background: var(--color-section-lighten-10);
color: var(--color-link-hover);
}
}
}
}
}

View File

@ -3,12 +3,11 @@
<h1 class="dialog-header">Over 18?</h1>
<div class="dialog-content">
<p>
You must be over the age of 18 and agree
to <%= link_to "the terms of service", terms_of_service_path, target: "_blank" %> to access this page.
You must be <b>18 years or older</b> and agree to the <%= link_to "terms of service", terms_of_service_path, target: "_blank" %> to access this website.
</p>
<p>
By default a limited blacklist has been applied hiding content that is commonly objected to. You may remove
items from this blacklist by using the blacklist menu item.
Content that is commonly considered objectionable is blacklisted by default.
You may remove tags from this blacklist using the corresponding menu item.
</p>
</div>
<div class="dialog-footer">