hexo-theme-stellar/source/css/_common/device.styl

85 lines
1.9 KiB
Stylus

.mobile-only
display: none
@media screen and (max-width: $device-mobile-max)
display: block !important
.mobile-hidden
@media screen and (max-width: $device-mobile-max)
display: none !important
.float-panel
position: sticky
grid-column-end: span 3
right: 0
bottom: 2rem
float: right
z-index: 10
display: flex
flex-direction: column
border-radius: $border-bar
margin-left: auto
margin-right: 1rem
@media screen and (min-width: $device-mobile-max)
margin-right: 2rem
overflow: hidden
--blur-px: 16px
--blur-bg: alpha(#fff, .4)
trans1: all
ondark()
--blur-bg: alpha(#000, .4)
if theme(dark)
ondark()
else if theme(auto)
@media (prefers-color-scheme: dark)
ondark()
//
.float-panel button
cursor: pointer
color: var(--text)
background: none
padding: 8px
line-height: 0
font-size: 28px
margin: 0
display: flex
>*
path#sep
trans1 transform
width: auto
height: 28px
//
.l_body[leftbar] .float-panel, .l_body[rightbar] .float-panel
box-shadow: 0 0 4px -1px $color-theme, 0 0 16px -4px $color-theme, 0 0 32px -12px $color-theme, 0 0 128px -32px $color-theme
.l_body[leftbar] .float-panel button.leftbar-toggle
background: var(--alpha100)
.l_body[leftbar] .float-panel button.leftbar-toggle
color: $color-theme
border-color: var(--block-border)
svg g
fill: currentColor
fill-opacity: 0.3
path#sep
transform: translateX(2px)
//
.l_body .l_right:empty+.float-panel button.rightbar-toggle
display: none !important
.l_body[rightbar] .float-panel button.rightbar-toggle
background: var(--alpha100)
.l_body[rightbar] .float-panel button.rightbar-toggle
color: $color-theme
border-color: var(--block-border)
svg g
fill: currentColor
fill-opacity: 0.3
path#sep
transform: translateX(2px)