<commit_before>import { NowPlaylistEffects } from '../../effects/now-playlist.effects';
import { getPlayer$, getCurrentMedia$, getIsPlayerPlaying$ } from '../../store/youtube-player/youtube-player.selectors';
import { isPlayerInRepeat$ } from '../../store/now-playlist/now-playlist.selectors';
import { EchoesState } from '../../store';
import { Store } from '@ngrx/store';
import {
  ChangeDetectionStrategy,
  Component,
  EventEmitter,
  HostBinding,
  Input,
  OnInit,
  Output
} from '@angular/core';
import { Observable } from 'rxjs/Observable';
import 'rxjs/add/operator/take';

import { NowPlaylistService, YoutubePlayerService } from '../../services';
import { PlayerActions, YoutubePlayerState } from '../../store/youtube-player';

@Component({
  selector: 'ep-player',
  styleUrls: [ './ep-player.scss' ],
  template: `
  <section 
    [class.show-youtube-player]="(player$ | async).showPlayer"
    [class.fullscreen]="(player$ | async).isFullscreen">
    <div class="yt-player ux-maker">
      <player-resizer 
        (toggle)="togglePlayer()"
        [fullScreen]="(player$ | async).showPlayer"
      ></player-resizer>
      <youtube-player class="nicer-ux"
        (ready)="setupPlayer($event)"
        (change)="updatePlayerState($event)"
      ></youtube-player>
    </div>
    <div class="container-fluid">
      <media-info class="col-md-5 col-xs-7"
        [player]="player$ | async"
        [minimized]="media$ | async"
        (thumbClick)="toggleFullScreen()"
      ></media-info>
      <player-controls class="col-md-4 col-xs-5 controls-container nicer-ux" 
        [isRepeat]="isPlayerInRepeat$ | async"
        [playing]="isPlayerPlaying$ | async"
        [media]="media$ | async"
        (pause)="pauseVideo()"
        (next)="playNextTrack()"
        (play)="playVideo($event)"
        (previous)="playPreviousTrack()"
        (repeat)="toggleRepeat()"
      ></player-controls>
    </div>
  </section>
  `,
  changeDetection: ChangeDetectionStrategy.OnPush
})
export class PlayerComponent implements OnInit {
  player$ = this.store.let(getPlayer$);
  media$ = this.store.let(getCurrentMedia$);
  isPlayerPlaying$ = this.store.let(getIsPlayerPlaying$);
  isPlayerInRepeat$ = this.store.let(isPlayerInRepeat$);

  @HostBinding('class.youtube-player') style = true;
<commit_msg>updated player controls for mobile<commit_after>import { NowPlaylistEffects } from '../../effects/now-playlist.effects';
import { getPlayer$, getCurrentMedia$, getIsPlayerPlaying$ } from '../../store/youtube-player/youtube-player.selectors';
import { isPlayerInRepeat$ } from '../../store/now-playlist/now-playlist.selectors';
import { EchoesState } from '../../store';
import { Store } from '@ngrx/store';
import {
  ChangeDetectionStrategy,
  Component,
  EventEmitter,
  HostBinding,
  Input,
  OnInit,
  Output
} from '@angular/core';
import { Observable } from 'rxjs/Observable';
import 'rxjs/add/operator/take';

import { NowPlaylistService, YoutubePlayerService } from '../../services';
import { PlayerActions, YoutubePlayerState } from '../../store/youtube-player';

@Component({
  selector: 'ep-player',
  styleUrls: [ './ep-player.scss' ],
  template: `
  <section 
    [class.show-youtube-player]="(player$ | async).showPlayer"
    [class.fullscreen]="(player$ | async).isFullscreen">
    <div class="yt-player ux-maker">
      <player-resizer 
        (toggle)="togglePlayer()"
        [fullScreen]="(player$ | async).showPlayer"
      ></player-resizer>
      <youtube-player class="nicer-ux"
        (ready)="setupPlayer($event)"
        (change)="updatePlayerState($event)"
      ></youtube-player>
    </div>
    <div class="container-fluid">
      <media-info class="col-md-5 col-xs-6"
        [player]="player$ | async"
        [minimized]="media$ | async"
        (thumbClick)="toggleFullScreen()"
      ></media-info>
      <player-controls class="col-md-4 col-xs-6 controls-container nicer-ux" 
        [isRepeat]="isPlayerInRepeat$ | async"
        [playing]="isPlayerPlaying$ | async"
        [media]="media$ | async"
        (pause)="pauseVideo()"
        (next)="playNextTrack()"
        (play)="playVideo($event)"
        (previous)="playPreviousTrack()"
        (repeat)="toggleRepeat()"
      ></player-controls>
    </div>
  </section>
  `,
  changeDetection: ChangeDetectionStrategy.OnPush
})
export class PlayerComponent implements OnInit {
  player$ = this.store.let(getPlayer$);
  media$ = this.store.let(getCurrentMedia$);
  isPlayerPlaying$ = this.store.let(getIsPlayerPlaying$);
  isPlayerInRepeat$ = this.store.let(isPlayerInRepeat$);

  @HostBinding('class.youtube-player') style = true;

{'fraction_non_alphanumeric': 0.17231699416972576, 'fraction_numerical': 0.0017274886633556468, 'mean_word_length': 3.5816023738872405, 'pattern_counts': {'":': 0, '<': 31, '<?xml version=': 0, '>': 31, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6887794', 'n_tokens_mistral': 1485, 'n_tokens_neox': 1444, 'n_words': 246}