Forum photos, a one-row bottom menu, and the site's own question windows
Photos in posts and replies: a "Fotó" button in the new thread form and the reply boxes. The browser makes the picture small before uploading it (1600 pixels at most, WebP, JPEG where WebP cannot be made); the forum checks it is a still picture, strips its metadata and makes a square preview (forum-photos/ in the storage). Five a member a day, five a post; one taken off before sending is deleted and does not count. Under the post a row of square previews; a click opens a viewer paged with arrows, swipes and keys. Seen by whoever may read the thread (long public cache only for public topics). Unsent photos go after a day, those of removed posts after a year; removed with the account and listed in the data export. Terms and privacy notice updated. The forum's bottom menu keeps its five items in one row (the fifth wrapped to a second row). On iPhones, when the keyboard goes away without the usual tap (a photo picker opening over it), the page is put back in place instead of the menu floating mid-screen over an empty strip. The browser's own confirm() and prompt() windows (23 places: deleting, revoking, blocking, muting, moderators' reasons, admin actions) are replaced by a question window in the site's look, following the forum's light or dark theme, with named buttons and a text box for reasons. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012vLHzh5qUhFtmJhzkcTbXL
This commit is contained in:
@@ -92,7 +92,8 @@ body:has(.forum[data-theme="light"]) .site-footer { background: #0d1220; }
|
||||
/* The forum's menu: a bar at the bottom on phones, tabs in the forum bar on wider screens. */
|
||||
.forum-nav {
|
||||
position: fixed; left: 0; right: 0; bottom: 0; z-index: 25;
|
||||
display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
|
||||
/* One row, as many equal columns as items. */
|
||||
display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr);
|
||||
background: var(--f-nav-bg); border-top: 1px solid var(--line);
|
||||
padding-bottom: env(safe-area-inset-bottom);
|
||||
box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
|
||||
@@ -805,3 +806,55 @@ a.fh-online-item:hover { color: var(--gold); }
|
||||
.ft-side .hint { font-size: 13px; }
|
||||
.ft-side strong { font-weight: 600; }
|
||||
}
|
||||
|
||||
/* --- photos in posts --- */
|
||||
.fphoto-btn { display: inline-flex; align-items: center; gap: 6px; }
|
||||
.fphoto-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
|
||||
.fphoto-picked { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
|
||||
.fnew-paper .fphoto-picked { padding: 0 18px 10px; }
|
||||
.fphoto-chip { position: relative; width: 64px; height: 64px; border-radius: 10px; overflow: hidden; background: var(--f-tint); }
|
||||
.fphoto-chip img { width: 100%; height: 100%; object-fit: cover; display: block; }
|
||||
.fphoto-busy img { opacity: 0.45; }
|
||||
.fphoto-remove {
|
||||
position: absolute; top: 3px; right: 3px; width: 22px; height: 22px; display: grid; place-items: center; padding: 0;
|
||||
border: 0; border-radius: 999px; background: rgba(10, 14, 24, 0.7); color: #fff; font-size: 15px; line-height: 1; cursor: pointer;
|
||||
}
|
||||
.fphoto-spinner {
|
||||
position: absolute; inset: 0; margin: auto; width: 22px; height: 22px; border-radius: 999px;
|
||||
border: 2px solid rgba(255, 255, 255, 0.5); border-top-color: var(--gold); animation: fphoto-spin 0.8s linear infinite;
|
||||
}
|
||||
@keyframes fphoto-spin { to { transform: rotate(360deg); } }
|
||||
@media (prefers-reduced-motion: reduce) { .fphoto-spinner { animation: none; } }
|
||||
.fnew-foot-left { display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap; }
|
||||
.fnew-photo-error { margin: 0 18px 10px; }
|
||||
|
||||
/* One row of square previews, a fixed height; more scroll sideways. */
|
||||
.fpics { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; scroll-snap-type: x proximity; padding-bottom: 2px; }
|
||||
.fpic {
|
||||
flex: none; width: 112px; height: 112px; padding: 0; border: 0; border-radius: 12px; overflow: hidden;
|
||||
background: var(--f-tint); cursor: zoom-in; scroll-snap-align: start;
|
||||
}
|
||||
.fpic img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 0.2s; }
|
||||
.fpic:hover img { transform: scale(1.04); }
|
||||
@media (min-width: 760px) { .fpic { width: 136px; height: 136px; } }
|
||||
|
||||
/* The viewer. */
|
||||
dialog.flight {
|
||||
width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
|
||||
background: rgba(5, 8, 16, 0.95); color: #fff; overflow: hidden;
|
||||
}
|
||||
dialog.flight::backdrop { background: transparent; }
|
||||
.flight-figure { margin: 0; width: 100%; height: 100%; display: grid; place-items: center; }
|
||||
.flight-img { max-width: 94vw; max-height: 86dvh; width: auto; height: auto; object-fit: contain; border-radius: 6px; user-select: none; }
|
||||
.flight-btn {
|
||||
position: absolute; display: grid; place-items: center; width: 48px; height: 48px; padding: 0; border: 0;
|
||||
border-radius: 999px; background: rgba(255, 255, 255, 0.12); color: #fff; font-size: 30px; line-height: 1; cursor: pointer;
|
||||
}
|
||||
.flight-btn:hover, .flight-btn:focus-visible { background: rgba(255, 255, 255, 0.24); }
|
||||
.flight-close { top: calc(14px + env(safe-area-inset-top)); right: 14px; font-size: 26px; }
|
||||
.flight-prev { left: 12px; top: 50%; transform: translateY(-50%); }
|
||||
.flight-next { right: 12px; top: 50%; transform: translateY(-50%); }
|
||||
.flight-count { position: absolute; bottom: calc(18px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); font-size: 14px; opacity: 0.8; }
|
||||
|
||||
/* The red button of a question window keeps its colour on hover in the light theme. */
|
||||
.forum[data-theme="light"] .btn-danger-solid:hover { background: #a93226; border-color: #a93226; color: #fff; }
|
||||
|
||||
Reference in New Issue
Block a user