Skip to content

Commit

Permalink
icons changed
Browse files Browse the repository at this point in the history
  • Loading branch information
webstermath committed Dec 9, 2018
1 parent ebd65a9 commit d012e1e
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 3 deletions.
18 changes: 18 additions & 0 deletions CSS/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,21 @@ html {
box-sizing: inherit;
}


.icon_play{
width: 0;
height: 0;
border-top: 8vmin solid transparent;
border-bottom: 8vmin solid transparent;
border-left: 13vmin solid white;
}
.icon_pause{
width: 12vmin;
height: 12vmin;
border-left: 4vmin solid white;
border-right: 4vmin solid white;
}

.invisible{
visibility: hidden;
}
Expand Down Expand Up @@ -146,6 +161,9 @@ body{

}
.track-controls__button_play{
display: flex;
justify-content: center;
align-items: center;
font-size: 4rem;
width: 30vmin;
height: 30vmin;
Expand Down
6 changes: 3 additions & 3 deletions audio.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export function getAudioWidget(saints){
const $nextTrackButton = $$('button').text('>').addClass('player-controls__button player-controls__button_track_next');
if(saintLen < 2) $nextTrackButton.hide();
const $trackControls = $$('div').addClass('track_controls')
const $trackPlayButton = $$('button').html('<div>►</div>').addClass('track-controls__button track-controls__button_play ')
const $trackPlayButton = $$('button').html('<div class="icon_play"></div>').addClass('track-controls__button track-controls__button_play ')
const $trackPlayButtonSpinner = $$('div').addClass('spinner track-controls__button-spinner_play')

//functions
Expand All @@ -32,8 +32,8 @@ export function getAudioWidget(saints){
}

function updateButton() {
const icon = $playerAudio[0].paused ? '' : '❚ ❚';
$trackPlayButton.html(`<div>${icon}</div>`);
const icon = $playerAudio[0].paused ? '<div class="icon_play"></div>' : '<div class="icon_pause"></div>';
$trackPlayButton.html(icon);
}

function resetTime(){
Expand Down

0 comments on commit d012e1e

Please sign in to comment.