Skip to content

Commit

Permalink
Merge pull request #351 from geichelberger/preview-content
Browse files Browse the repository at this point in the history
Allow configuring preview-content background color
  • Loading branch information
ferserc1 authored Apr 18, 2024
2 parents 9606e56 + f650016 commit 52cae4a
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 13 deletions.
12 changes: 12 additions & 0 deletions src/css/PreviewContainer.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
.preview-container {
background-color: var(--preview-container-background-color);
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
position: absolute;
top: 50%;
transform: translateY(-50%);
}
1 change: 1 addition & 0 deletions src/css/colors.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
--main-bg-gradient: linear-gradient(0deg, rgba(32,32,32,1) 0%, rgba(32,32,32,0.49531687675070024) 72%, rgba(32,32,32,0.08355217086834732) 100%);
--main-border-color: rgba(125,125,125,0.4);
--video-container-background-color: #e4e4e4;
--preview-container-background-color: #e4e4e4;
--base-video-rect-background-color: #8a8a8a;
--main-outline-color: var(--highlight-bg-color-hover);
}
15 changes: 2 additions & 13 deletions src/js/core/PreviewContainer.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,8 @@

import { DomClass, createElementWithHtmlText } from './dom';

const g_style = `
background-color: #e4e4e4;
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
position: absolute;
top: 50%;
transform: translateY(-50%);
`
import 'paella-core/styles/PreviewContainer.css';

const g_imgStyle = `
width: 100%;
`;
Expand Down Expand Up @@ -51,7 +41,6 @@ export default class PreviewContainer extends DomClass {
constructor(player, parentElement,backgroundImage,backgroundImagePortrait) {
const attributes = {
"class": "preview-container",
"style": g_style,
"role": "button",
"aria-label": "Play video"
};
Expand Down

0 comments on commit 52cae4a

Please sign in to comment.