Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for better control bar #3

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
158 changes: 95 additions & 63 deletions dist/borealis.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/borealis.css.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/borealis.min.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/pages/room/player/_all.sass
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
@import "wrapper.sass"
@import "footer.sass"
@import "control-bar.sass"
78 changes: 78 additions & 0 deletions src/pages/room/player/control-bar.sass
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
div.player
&.has-control
div.control-bar
display: none

&:not(.has-control)
&:hover
div.control-bar
bottom: 0
opacity: 1
pointer-events: all

div.control-bar
position: absolute

transition: $softTransition
background: linear-gradient(to bottom, #00000000, #000000a3)

left: 0
width: 100%

bottom: -20px
opacity: 0
pointer-events: none
height: 60px
width: 100%

div.control-inner
height: 40px
margin-top: 20px

display: flex
flex-direction: row
justify-content: space-between

.fullscreen-toggle
margin: auto 20px

div.volume-controls
display: flex

align-items: center
justify-content: center

margin: 10px 20px

img.icon
margin-right: 10px

img.icon
cursor: pointer

// @media screen and (prefers-color-scheme: dark)
filter: invert(1)

div.volume-slider
transform: translate(0, -300%)
margin: auto auto
height: 3px
background: white
-webkit-appearance: none
cursor: pointer

.volume-slider:focus
outline: none

.volume-slider::-webkit-slider-thumb
-webkit-appearance: none
width: 12px
height: 12px
border-radius: 50%
background: white

.volume-slider::-moz-range-thumb
width: 12px
height: 12px
border-radius: 50%
background: white
52 changes: 4 additions & 48 deletions src/pages/room/player/footer.sass
Original file line number Diff line number Diff line change
Expand Up @@ -12,64 +12,20 @@ div.player-footer
overflow-x: auto
overflow-y: hidden

div.control-bar
display: flex
flex-direction: row
justify-content: space-between
height: 40px
width: 100%
margin: auto

.fullscreen-toggle
margin: auto 20px

.volume-controls
width: 10%
margin: 10px 20px

.volume-slider
transform: translate(0, -300%)
margin: auto 0
height: 3px
background: white
-webkit-appearance: none
cursor: pointer

.volume-slider:focus
outline: none


.volume-slider::-webkit-slider-thumb
-webkit-appearance: none
width: 12px
height: 12px
border-radius: 50%
background: white


.volume-slider::-moz-range-thumb
width: 12px
height: 12px
border-radius: 50%
background: white


img.icon
cursor: pointer
@media screen and (prefers-color-scheme: dark)
filter: invert(1)

div.user-icons
display: flex

width: fit-content

padding: 0px 40px 40px 40px
padding: 40px 40px 40px 40px
margin: auto

align-items: center
justify-content: stretch

.has-no-padding-top
padding-top: 0

div.user-icon
width: $userIconSize
height: $userIconSize
Expand Down