• Урок 1. 00:15:42
    unnamed 1
  • Урок 2. 00:06:45
    unnamed 2
  • Урок 3. 00:01:45
    unnamed 3
  • Урок 4. 00:05:48
    unnamed 4
  • Урок 5. 00:22:59
    unnamed 5
  • Урок 6. 00:10:38
    unnamed 6
  • Урок 7. 00:30:18
    unnamed 7
  • Урок 8. 00:25:41
    unnamed 8
  • Урок 9. 00:25:01
    unnamed 9
  • Урок 10. 00:09:26
    unnamed 10
  • Урок 11. 00:26:26
    unnamed 11
  • Урок 12. 00:21:56
    unnamed 12
  • Урок 13. 00:29:06
    unnamed 13
  • Урок 14. 00:09:38
    unnamed 14
  • Урок 15. 00:11:05
    unnamed 15
  • Урок 16. 00:15:55
    unnamed 16
  • Урок 17. 00:14:49
    unnamed 17
  • Урок 18. 00:12:35
    unnamed 18
  • Урок 19. 00:17:21
    unnamed 19
  • Урок 20. 00:10:15
    unnamed 20
  • Урок 21. 00:11:32
    unnamed 21
  • Урок 22. 00:08:43
    unnamed 22
  • Урок 23. 00:13:15
    unnamed 23
  • Урок 24. 00:03:13
    unnamed 24
  • Урок 25. 00:23:10
    unnamed 25
  • Урок 26. 00:23:52
    unnamed 26
  • Урок 27. 00:07:17
    unnamed 27
"use strict"; (function () { localStorage.removeItem('less'); var lessons = []; var list = document.querySelectorAll('.lessons-item'); if (list) { Array.prototype.forEach.call(list, function (element) { element.addEventListener('click', function (e) { var index = e.currentTarget.getAttribute('data-index'); if(myPlayer === undefined) { localStorage.setItem('less', index); playerb.dispatchEvent(new Event('click')); } else { myPlayer.api("find","c607"+index); myPlayer.api('play'); } }) }); } var playerb = document.querySelector('.player-play') if (playerb) { playerb.addEventListener('click', function () { axios.get('/course/607/lessons').then(function (_ref) { playerb.classList.add('player-play_active'); lessons = _ref.data; loadPlayer(); }).catch(function (error) { alert(error); }); }, {once: true}); } if(typeof window.URLSearchParams) { var searchParams = new URLSearchParams(location.search); if(searchParams.has('lesson')) { var l = String(Number(searchParams.get("lesson"))); addClassToLastVideo(l); } } function addClassToLastVideo(num) { localStorage.setItem('less', num); var element = document.querySelector('.lessons-item[data-index="'+num+'"]'); if(element) { setTimeout(function (){ document.getElementById('player').scrollIntoView({block: "center", behavior: "smooth"}); }, 1000) element.classList.add('lessons-item_active'); if(element.closest('body').clientWidth > 991) { element.closest('.lessons-list').scrollTop = element.offsetTop; } } } function loadPlayer() { var myScript = document.createElement("script"); myScript.setAttribute("src", "/libraries/playerjsa.js?ver=796e277f"); myScript.setAttribute("type", "text/javascript"); myScript.addEventListener("load", scriptLoaded, false); document.body.insertBefore(myScript, document.querySelector('.footer')); } function scriptLoaded() { ichp(lessons); } var myPlayer; var player = document.getElementById("player"); function ichp(playList) { myPlayer = new Playerjs({id: "player", file: playList, autoplay: 1, lang: 'ru'}); } if (player) { player.addEventListener("error", function (e) { console.log(e); }); player.addEventListener("play", function (e) { var playlistId = myPlayer.api('playlist_id'); var currentLess = playlistId.substring(String('c607').length); setActiveLesson(currentLess, e.target.closest('body').clientWidth); try { var link = String(window.location.origin) + String(window.location.pathname) + '?lesson=' + String(currentLess); window.history.replaceState(null, null, link); } catch (e) { console.error(e); } }) player.addEventListener("init", function () { var less = localStorage.getItem('less'); if(less) { myPlayer.api("find","c607"+less); myPlayer.api('play'); localStorage.removeItem('less'); } }); } function setActiveLesson(num, width) { if (list && list.length) { Array.prototype.forEach.call(list, function (element) { if(element.getAttribute('data-index') === num) { element.classList.add('lessons-item_active'); if(width > 991) { element.closest('.lessons-list').scrollTop = element.offsetTop; } } else { element.classList.remove('lessons-item_active'); } }); } } window.playerWideMode = false; window.PlayerWideMode = function(){ if(playerWideMode){ document.querySelector(".player").classList.remove('player-full'); } else { document.querySelector(".player").classList.add('player-full'); } window.playerWideMode = !window.playerWideMode; } })();