Skip to content

Commit

Permalink
Disable volume dropdown scrolling on desktop
Browse files Browse the repository at this point in the history
Make pill-scrollbar a global class
  • Loading branch information
SteveMicroNova committed Jan 7, 2025
1 parent def1c5a commit 25c0309
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 33 deletions.
30 changes: 30 additions & 0 deletions web/src/App.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,33 @@
height: 100vh;
background-color: green;
}


.pill-scrollbar {
max-height: inherit;
overflow-y: auto;
}

.pill-scrollbar::-webkit-scrollbar {
width: 12px;
height: 12px;
}

.pill-scrollbar::-webkit-scrollbar-track {
background: transparent;
}

.pill-scrollbar::-webkit-scrollbar-thumb {
background-color: rgba(0, 0, 0, 0.5);
border-radius: 999px;
border: 3px solid rgba(255, 255, 255, 0.5);
}

.pill-scrollbar::-webkit-scrollbar-thumb:hover {
background-color: rgba(0, 0, 0, 0.7);
}

.pill-scrollbar {
scrollbar-width: thin;
scrollbar-color: rgba(0, 0, 0, 0.5) transparent;
}
30 changes: 0 additions & 30 deletions web/src/components/ModalCard/ModalCard.scss
Original file line number Diff line number Diff line change
Expand Up @@ -47,33 +47,3 @@
.modal-footer-button {
@include general.button-hover;
}


.pill-scrollbar {
max-height: inherit;
overflow-y: auto;
}

.pill-scrollbar::-webkit-scrollbar {
width: 12px;
height: 12px;
}

.pill-scrollbar::-webkit-scrollbar-track {
background: transparent;
}

.pill-scrollbar::-webkit-scrollbar-thumb {
background-color: rgba(0, 0, 0, 0.5);
border-radius: 999px;
border: 3px solid rgba(255, 255, 255, 0.5);
}

.pill-scrollbar::-webkit-scrollbar-thumb:hover {
background-color: rgba(0, 0, 0, 0.7);
}

.pill-scrollbar {
scrollbar-width: thin;
scrollbar-color: rgba(0, 0, 0, 0.5) transparent;
}
2 changes: 1 addition & 1 deletion web/src/pages/Player/Player.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ const Player = () => {
</IconButton>
</div>

<div className={`player-volume-body ${expanded ? "expanded-volume-body" : ""}`}>
<div className={`player-volume-body pill-scrollbar ${expanded ? "expanded-volume-body" : ""}`}>
<VolumeZones open={(expanded || alone)} sourceId={selectedSourceId} zones={zonesLeft} groups={usedGroups} groupsLeft={groupsLeft} />
</div>
</Card>
Expand Down
6 changes: 4 additions & 2 deletions web/src/pages/Player/Player.scss
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,10 @@
display: flex;
align-items: center;
flex-direction: column;
max-height: calc(85vh - 120px);
overflow-y: auto;
@media (max-width: 435px) {
max-height: calc(85vh - 120px);
overflow-y: auto;
}
}

.expanded-volume-body {
Expand Down

0 comments on commit 25c0309

Please sign in to comment.