Files
wordpress-theme-aksrt/assets/css/routes/sign.css
T
kate522 00ae62f62b fix(auth): close the modal regressions and keep the header component off /sign/
Three defects slipped into the sign-card rebuild:

The hidden-glyph rule was dropped. `.fa` sets display:inline-block, which
outranks the UA [hidden] rule, so every hidden glyph stayed visible — most
visibly a spinner rendered beside the login button at rest. `.sign [hidden]`
restores the override.

Closing account login produced an empty shell. The whole sign-in pane was
gated on `!$close_signin`, and the social block carried the same gate, so a
site with account login off but registration on still opened on an empty
panel with no social entry. The pane is now rendered in three shapes: open
registration falls through to the signup tab, a QR entry falls through to
the QR tab, social-only renders a notice plus the social bar, and when
nothing is available it states that login is closed.

The modal close button sat in normal flow and pushed the card content down;
`#u_sign .sign > .close` pins it back to the top-right corner.

The /sign/ route is `index.php?jio_sign=1`, so WordPress reports it as home.
The header multifunction component resolves page type by query flags and the
home branch won, so the component appeared on the auth page whenever "首页"
was in its scope — even though the sign page template itself was already
excluded. `jio_header_slide_current_page_type()` now bails out on `jio_sign`
before any of the is_* checks.

The breakpoint overrides that were fighting the shared sheet between 641px
and 991px are narrowed to the one offset that actually needed adjusting.

Verification: the modal was rendered through a PHP stub, served with the real
theme stylesheets, and driven by the real auth.js in a headless browser —
tab switching, signin-mode switching, password reveal, close button and
geometry at 1440/1100/900/760/500/390px. The header harness gained a
`jio_sign` case asserting no markup, and 860 widget/navigation tests pass.
2026-11-04 16:51:41 +08:00

143 lines
2.6 KiB
CSS

/* Authentication surfaces: modal (#u_sign) and the /sign/ page.
*
* Card, line inputs, tab panes, social bar and title rules come from the shared
* theme stylesheet; this file only positions the shells around them.
*/
#u_sign.jio-auth-modal {
z-index: 100050;
}
#u_sign.jio-auth-modal.in {
display: block;
overflow-x: hidden;
overflow-y: auto;
background: rgba(0, 0, 0, 0.4);
}
#u_sign.jio-auth-modal .modal-dialog {
opacity: 0;
transform: translateY(-12px);
transition: opacity 0.2s ease, transform 0.25s ease;
}
#u_sign.jio-auth-modal.in .modal-dialog {
opacity: 1;
transform: none;
}
#u_sign .sign-img {
inset: 0;
overflow: hidden;
}
#u_sign .sign-img img {
display: block;
width: 100%;
height: 100%;
border-radius: var(--main-radius);
object-fit: cover;
}
/* The shared sheet leaves the modal close button in normal flow, so it would
* push the card content down. */
#u_sign .sign > .close {
position: absolute;
top: 10px;
right: 15px;
z-index: 3;
font-size: 18px;
}
/* .fa sets display:inline-block, which outranks the UA [hidden] rule, so every
* hidden glyph (spinner, password eye) stayed visible without this. */
.sign [hidden] {
display: none !important;
}
body.auth-modal-open {
overflow: hidden;
}
/* ---- /sign/ page shell ---- */
.page-template-user-sign {
min-height: 500px;
}
.page-template-user-sign > .fixed {
z-index: 0;
}
.sign-page {
position: relative;
z-index: 1;
min-height: 500px;
padding-top: 70px;
padding-bottom: 60px;
}
.sign-row {
min-height: calc(100vh - 130px);
display: flex;
flex-wrap: wrap;
}
.sign-page .sign {
width: 350px;
}
.sign-col {
display: flex;
justify-content: center;
align-items: center;
}
.sign-page-footer {
top: auto;
height: auto;
padding: 10px;
z-index: 2;
}
/* ---- card internals ---- */
.sign .sign-passw {
border: 0;
background: none;
padding: 0;
line-height: 1;
cursor: pointer;
}
.sign .oauth-data-box .muted-box {
margin-bottom: 10px;
}
.sign .oauth-data-box .avatar-img {
--this-size: 60px;
}
.sign [data-auth-qr-content] {
display: grid;
place-items: center;
min-height: 180px;
}
.sign .qrcode-signin-container button[data-auth-refresh-qr] {
border: 0;
background: none;
padding: 10px;
color: var(--focus-color);
cursor: pointer;
}
.sign [data-invite-feedback].is-error {
color: #ff5473;
}
/* Between the 992px split and the 640px collapse the shared sheet still offsets
* the card by 55%, but the dialog has already shrunk — give the card the room. */
@media (max-width: 991px) and (min-width: 641px) {
#u_sign .sign-img + .sign {
margin-left: 45%;
}
}