Skip to content

Commit

Permalink
Update styles and player logic
Browse files Browse the repository at this point in the history
  • Loading branch information
AshurovG committed Dec 16, 2024
1 parent ac31ad1 commit e809516
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 8 deletions.
16 changes: 13 additions & 3 deletions public/components/Loader/Loader.scss
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
@import 'styles/variables.scss';

.loader {
width: 75px;
height: 75px;
border: 10px solid rgba(148, 12, 207, 0.6);
width: 40px;
height: 40px;
border: 5px solid rgba(148, 12, 207, 0.6);
border-radius: $border-radius-max;
border-left-color: $brand;
animation: loader 1.3s linear infinite;
Expand All @@ -29,3 +29,13 @@
transform: rotate(360deg);
}
}

// @include mobileLandscape {
// .loader {
// width: 50px;
// height: 50px;
// border: 7px solid rgba(148, 12, 207, 0.6);
// // Убедитесь, что анимация не переопределяется
// animation: loader 1.3s linear infinite;
// }
// }
1 change: 1 addition & 0 deletions public/components/UsersList/UsersList.scss
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
&_avatar {
width: 50px;
height: 50px;
border-radius: $border-radius-max;
}

&_username {
Expand Down
10 changes: 5 additions & 5 deletions public/components/VideoPlayer/VideoPlayer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,9 @@ export class VideoPlayer {
video.addEventListener('ended', this.onVideoEnd.bind(this));

// TODO: проверить на мобилке
if (this.#isModal) {
video.addEventListener('loadeddata', this.hidePlaceholder.bind(this));
}
// if (this.#isModal) {
video.addEventListener('loadeddata', this.hidePlaceholder.bind(this));
// }

fullOrSmallScreen.addEventListener(
'click',
Expand Down Expand Up @@ -374,7 +374,7 @@ export class VideoPlayer {

// TODO: проверить на мобилке
if (!this.#isModal) {
this.hidePlaceholder();
// this.hidePlaceholder();

if (isTouchDevice() && isTabletOrMobileLandscape()) {
const controls = document.querySelector(
Expand Down Expand Up @@ -796,8 +796,8 @@ export class VideoPlayer {
this.#controls.videoWrapper.classList.remove('hidden');
if (this.#isModal) {
this.#controls.videoBackButton.classList.remove('video__controls_hidden');
this.#controls.videoTitle.classList.remove('video__controls_hidden');
}
this.#controls.videoTitle.classList.remove('video__controls_hidden');

this.#controls.videoMobileControls?.classList.remove(
'video__controls_hidden',
Expand Down

0 comments on commit e809516

Please sign in to comment.