lbry-desktop/ui/scss/component/_content.scss

147 lines
2.7 KiB
SCSS

.content__viewer {
@extend .card;
position: absolute;
top: var(--spacing-large);
}
.content__viewer--inline {
max-height: var(--inline-player-max-height);
@media (max-width: $breakpoint-small) {
margin-top: 10px;
}
}
.content__viewer--floating {
position: fixed;
margin-bottom: 0;
height: calc(var(--floating-viewer-height) + var(--floating-viewer-info-height));
overflow: hidden;
left: calc(var(--spacing-large) + var(--spacing-small));
z-index: 9999;
&:hover {
.content__actions,
.content__floating-header {
visibility: visible;
}
}
}
.content__wrapper {
position: relative;
width: 100%;
height: 100%;
}
.content__wrapper--floating {
height: var(--floating-viewer-height);
width: var(--floating-viewer-width);
}
.content__actions {
visibility: hidden;
display: flex;
.button {
@extend .button--close;
height: 1.5rem;
top: 0;
position: relative;
margin-left: var(--spacing-small);
svg {
color: var(--color-white);
}
}
}
.content__floating-header {
visibility: hidden;
position: absolute;
top: 0;
width: 100%;
height: 2rem;
display: flex;
justify-content: space-between;
line-height: 1.5rem;
padding: 0.25rem;
background-color: var(--color-background);
}
.content__actions,
.content__floating-header {
z-index: 1;
}
.content__info {
cursor: grab;
height: var(--floating-viewer-info-height);
padding: var(--spacing-medium);
display: flex;
flex-direction: column;
align-items: flex-start;
white-space: nowrap;
}
.content__cover {
@include thumbnail;
position: relative;
display: flex;
align-items: center;
justify-content: center;
background-position: 50% 50%;
background-repeat: no-repeat;
background-size: 100%;
max-height: var(--inline-player-max-height);
margin: auto;
&:not(.card__media--nsfw) {
background-color: #000; // solid black to blend nicely when the video starts (if it doesn't take the full width)
}
&:hover {
cursor: pointer;
}
&:-webkit-full-screen {
width: 100%;
height: 100%;
}
}
.content__cover--disabled {
@include thumbnail;
cursor: default;
position: relative;
display: flex;
align-items: center;
justify-content: center;
background-position: 50% 50%;
background-repeat: no-repeat;
background-size: 100%;
margin: auto;
&:-webkit-full-screen {
width: 100%;
height: 100%;
}
}
.content__cover--hidden-for-text {
display: none;
}
.content__loading {
height: 100%;
display: flex;
align-items: center;
flex-direction: column;
justify-content: center;
padding: 0 var(--spacing-large);
background-color: #000;
}
.content__loading-text {
color: var(--color-white);
}