diff options
Diffstat (limited to 'src/style.css')
| -rw-r--r-- | src/style.css | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/src/style.css b/src/style.css index 38aa2ac..f036fb8 100644 --- a/src/style.css +++ b/src/style.css @@ -2218,3 +2218,51 @@ html:has(.call-overlay:not(.call-min)) { overflow: hidden; scrollbar-gutter: aut pointer-events: none; opacity: 0; transition: opacity .12s, transform .12s; } .feed-when.on { opacity: 1; transform: translate(-50%, 0); transition-duration: .08s; } + +/* A PAFF song or album in a post: cover, title, play. It plays in the + music bar, not here (paffSongCard / playInBar in messages.js). */ +.paff-song { + display: flex; align-items: center; gap: 12px; margin-top: 6px; padding: 8px; + border: 1px solid var(--line); border-radius: 10px; background: var(--surface2); + cursor: pointer; position: relative; +} +.paff-song:hover { border-color: var(--line-strong); } +.paff-song.on { border-color: var(--accent, var(--line-strong)); } +.paff-song-cover { width: 64px; height: 64px; flex: none; border-radius: 6px; object-fit: cover; background: var(--line); } +.paff-song-meta { min-width: 0; flex: 1; } +.paff-song-title { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } +.paff-song-meta .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } +.paff-song-play { + flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; + background: var(--fill); color: var(--fill-fg); +} +.paff-song-open { position: absolute; top: 4px; right: 8px; font-size: 13px; color: var(--faint); text-decoration: none; } + +/* The music bar: PAFF's slim player, pinned above the bottom nav and + outside the page, so a song plays on wherever you go. */ +.music-bar { + position: fixed; z-index: 29; left: 50%; transform: translateX(-50%); + bottom: env(safe-area-inset-bottom, 0px); + width: min(560px, 100%); height: 64px; box-sizing: border-box; + display: flex; align-items: stretch; + background: #0a0b0e; /* PAFF's player's own */ border: 1px solid var(--line); border-bottom: 0; + border-radius: 12px 12px 0 0; box-shadow: 0 -4px 18px rgba(0, 0, 0, .08); overflow: hidden; +} +body:has(.app-bottom-nav) .music-bar { bottom: calc(env(safe-area-inset-bottom, 0px) + 65px); } +.music-bar iframe { flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; } +.music-close { + flex: none; width: 40px; margin: 0; padding: 0; border: 0; border-radius: 0; + background: none; color: rgba(255, 255, 255, .6); font-size: 22px; cursor: pointer; +} +.music-close:hover { color: #fff; background: none; } +body.music-open .feed-post-fab, body.music-open .feed-new-pill { bottom: calc(env(safe-area-inset-bottom, 0px) + 82px + 68px); } +body.music-open #app { padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px)); } +body.music-open #app:has(> .app-bottom-nav) { padding-bottom: calc(150px + env(safe-area-inset-bottom, 0px)); } +@media (min-width: 900px) { + .music-bar, body:has(.app-bottom-nav) .music-bar { + left: calc(50% + var(--col-mid)); bottom: 16px; width: min(600px, calc(100% - 32px)); + border-radius: 12px; border-bottom: 1px solid var(--line); + } + body.music-open .feed-post-fab, body.music-open .feed-new-pill { bottom: 96px; } + body.music-open #app:has(> .app-bottom-nav) { padding-bottom: 96px; } +} |
