practisemaster 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.gitpod.yml +10 -0
- package/nonobfs/PMbundle.js +1 -1
- package/package.json +1 -1
- package/nonobfs/PMwrapper.js +0 -3
- package/nonobfs/bob.js +0 -14
- package/nonobfs/bundlesForTests/PMErrorBundle.js +0 -296
- package/nonobfs/bundlesForTests/PMbundle.js +0 -296
- package/nonobfs/bundlesForTests/test.txt +0 -1
package/.gitpod.yml
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# This configuration file was automatically generated by Gitpod.
|
|
2
|
+
# Please adjust to your needs (see https://www.gitpod.io/docs/introduction/learn-gitpod/gitpod-yaml)
|
|
3
|
+
# and commit this file to your remote git repository to share the goodness with others.
|
|
4
|
+
|
|
5
|
+
# Learn more from ready-to-use templates: https://www.gitpod.io/docs/introduction/getting-started/quickstart
|
|
6
|
+
|
|
7
|
+
tasks:
|
|
8
|
+
- init: npm install
|
|
9
|
+
|
|
10
|
+
|
package/nonobfs/PMbundle.js
CHANGED
|
@@ -222,7 +222,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac
|
|
|
222
222
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
223
223
|
|
|
224
224
|
"use strict";
|
|
225
|
-
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var _player_pm__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./player-pm */ \"./src/modules/player-pm.js\");\n/* harmony import */ var _pageSupport_pm__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./pageSupport-pm */ \"./src/modules/pageSupport-pm.js\");\n/**\n * module allows for the newing of a PractiseMaster class \n * a global window.PractiseMaster is created\n * \n * @module PractiseMaster Module\n * @requires Player Module\n * @requires PageSupport Module\n */\n\n\n\n\n\n/**\n * entry point for PractiseMaster js plugin: new PractiseMaster();\n * @class PractiseMaster\n * @property {mehtod} globals() - returns window.PractiseMaster\n * @property {method} player() - news up a Player class for each pm class element\n * @property {declaration} getElementsByClassName(\"pm\") - Elements to update with a player \n * @property {declaration} getElementsByClassName(\"pmlinkbuilder\") - Elements to update with a player \n * @property {class} PageSupport(siteCSS) - news this up with any site specific css\n * @property {object} siteCSS - an object for css specific to the host site (ex WordPress)\n */\n\nclass PractiseMaster {\n\n constructor(siteCSS) {\n\n this.globals();\n\n this.pmElements = document.getElementsByClassName(\"pm\");\n\n this.linkBuilderElements = document.getElementsByClassName(\"pmlinkbuilder\");\n\n Array.from(this.linkBuilderElements).forEach(el => {\n\n this.addLinkBuilderHTML(el);\n this.startLinkBuilder();\n\n });\n\n // site (ex WordPress css) goes on page once with PageSupport\n this.PageSupport = new _pageSupport_pm__WEBPACK_IMPORTED_MODULE_1__[\"default\"](siteCSS);\n\n this.player();\n\n this.siteCSS = siteCSS;\n\n }\n\n\n\n /**\n * instantiates any global variables from the PractiseMaster class\n * @method\n */\n\n globals() {\n\n window.PractiseMaster = this;\n\n }\n\n\n\n /**\n * news-up a Player class for each of [PMelements]\n * @method\n */\n\n player() {\n\n console.log(this.pmElements.length + \" 'pm' video or audio players created\");\n\n Array.from(this.pmElements).forEach((el) => {\n // Do stuff here\n console.log(el.tagName);\n\n this[\"PM_\" + el.id] = new _player_pm__WEBPACK_IMPORTED_MODULE_0__[\"default\"](el);\n\n });\n\n }\n\n\n\n /**\n * adds LinkBuilder form and tutorial HTML to DOM\n * @method\n * @param {Element} el eleent with pmlinkbuilder class\n */\n\n addLinkBuilderHTML(el) {\n\n el.insertAdjacentHTML('afterbegin',\n\n `\n <h1>PractiseMaster Precision Link Builder</h1>\n <br>\n <br>\n <br>\n\n <h2> Build loops and copy video embed html:</h2>\n\n <h3> Step 0:</h3>\n <div>If you need to:</div><button id=\"refresh\" onclick=\"location.reload();\">Start Again</button>\n\n <h3> Step 1:</h3>\n \n <fieldset>\n <legend>Please select your preferred video/audio source:</legend>\n <div>\n <input type=\"radio\" id=\"source1\" name=\"source\" value=\"vimeo\" />\n <label for=\"source1\">Vimeo</label>\n <input type=\"radio\" id=\"source2\" name=\"source\" value=\"youtube\" />\n <label for=\"source2\">YouTube</label>\n \n </div>\n <label for=\"providerVidID\">YouTube or Vimeo ID</label>\n <input id=\"providerVidID\" type=\"text\">\n <div>\n <br> \n <div>\n <input type=\"radio\" id=\"source3\" name=\"source\" value=\"MP4\" />\n <label for=\"source3\">MP4</label>\n <input type=\"radio\" id=\"source4\" name=\"source\" value=\"MP3\" />\n <label for=\"source4\">MP3</label>\n <input type=\"radio\" id=\"source3\" name=\"source\" value=\"OGG\" />\n <label for=\"source3\">OGG</label>\n </div>\n <label for=\"sourceURL\">Hosted Source</label>\n <input id=\"sourceURL\" type=\"text\"> (Public URL)\n <div>\n <br>\n <button id=\"doIt\">Start Video</button>\n </div>\n <br>\n <br>\n <fieldset>\n <div>\n If you need sources to try:\n <ul>\n <li>Vimeo: 76979871 <button class=\"demoButton\" id=\"doVimeo\">Start Vimeo</button>\n <li>YouTube: bTqVqk7FSmY <button class=\"demoButton\" id=\"doYT\">Start YouTube</button>\n <li>MP4 Video: https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-720p.mp4 <button class=\"demoButton\" id=\"doMP4\">Start MP4</button>\n <li>MP3 Audio: https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.mp3 <button class=\"demoButton\" id=\"doMP3\">Start MP3</button>\n <li>OGG Audio: https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.ogg <button class=\"demoButton\" id=\"doOGG\">Start OGG</button>\n </ul>\n </div>\n </fieldset>\n </fieldset>\n \n\n\n <div id=\"copyInputDiv\"style=\"display: none;\" >\n\n <br>\n <br>\n <br>\n\n <h2> Step 2: Copy video embed </h2>\n <label for=\"vidDivDisplay\">Video Embed</label><input style=\"width: -webkit-fill-available;\" id=\"vidDivDisplay\" disabled >\n \n\n <br>\n <br>\n <br>\n <h1>Step 3: Build Loops (<svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"fak\" data-icon=\"light-link-circle-arrow-down\" role=\"img\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 610 510\" class=\"uploaded-icon-preview svg-inline--fa fa-light-link-circle-arrow-down\" style=\"width: 31px;height: 22px;\"><path fill=\"currentColor\" d=\"M173 131.4c49.1-49.9 130.9-49.9 180.8 0c26.2 26.2 38.5 61 37 95.5c-28 20.9-49.6 50-61.2 83.7c-4.2-5.8-4-14 .9-19.8c1.8-2.1 3.6-4.1 5.4-6.2c32.9-38 30.9-95-4.7-130.5c-37.4-37.5-98.1-37.5-135.5 0c-41.5 41.5-83.1 83-124.6 124.5c-37.5 37.5-37.5 98.3 0 135.8c37.5 37.5 98.3 37.5 135.8 0c7.5-7.5 15.1-15.1 22.6-22.6c6.2-6.3 16.4-6.3 22.6 0c6.3 6.2 6.3 16.3 0 22.6c-7.5 7.5-15.1 15.1-22.6 22.6c-50 50-131 50-181 0s-50-131.9 0-181c41.5-41.5 83-83.1 124.5-124.6zM286.2 380.6c-47.5-47.5-50.2-123.5-7.1-174.2c2.1-2 4.1-4.1 6.2-6.1c5.8-6.7 15.9-7.4 22.6-1.6c6.6 5.7 7.4 15.8 1.6 22.5c-1.8 2.1-3.6 4.1-5.4 6.2c-32.9 38-30.9 95 4.7 130.5c3.5 3.5 7.3 6.8 11.2 9.6c0 .2 0 .3 0 .5c0 13.4 1.5 26.4 4.3 38.9c-13.8-6.2-26.8-15-38.1-26.3zm282.7-283c-37.5-37.5-98.3-37.5-135.8 0c-7.5 7.5-15.1 15.1-22.6 22.6c-6.2 6.3-16.4 6.3-22.6 0c-6.3-7.1-6.3-16.3 0-22.6c7.5-7.5 15.1-15.1 22.6-22.6c50-50 131-50 181 0c43.2 42.4 49.1 109.2 17.7 158.3c-8.1-6.8-16.8-12.9-26-18.1c22.3-36.9 17.6-85.7-14.3-117.5zM496 480c40 0 77-21.3 97-56s20-77.3 0-112s-57-56-97-56s-77 21.3-97 56s-20 77.3 0 112s57 56 97 56zm0-256c51.4 0 99 27.4 124.7 72s25.7 99.4 0 144S547.4 512 496 512s-99-27.4-124.7-72s-25.7-99.4 0-144s73.3-72 124.7-72zm67.3 163.3l-56 56c-6.2 6.3-16.4 6.3-22.6 0c-18.7-18.7-37.3-37.3-56-56c-6.2-6.2-6.2-16.4 0-22.6s16.4-6.2 22.6 0c9.6 9.6 19.1 19.1 28.7 28.7c0-29.8 0-59.6 0-89.4c0-8.8 7.2-16 16-16s16 7.2 16 16c0 29.8 0 59.6 0 89.4c9.6-9.6 19.1-19.1 28.7-28.7c6.2-6.2 16.4-6.2 22.6 0s6.2 16.4 0 22.6z\" class=\"\"></path></svg>).</h1>\n <h3>Your Links Appear Below Video</h3>\n <br>\n <br>\n <br>\n </div>\n \n \n <div class=\"container\" style=\"max-width: 75%;\"></div>\n \n \n \n `\n );\n\n }\n\n\n\n /**\n * event listener for #doIt button\n * adds disabled text box and copy button and calls this.player()\n * @method\n */\n\n startLinkBuilder() {\n\n this.addDoITButtonListener();\n this.addDoDemosButtonListener();\n\n }\n\n addDoDemosButtonListener() {\n\n\n\n // 'submit' from the LoopBuilder form\n\n const buttons = document.querySelectorAll(\"button.demoButton\");\n\n buttons.forEach(button =>\n\n button.addEventListener(\n \"click\",\n (event) => {\n //create new div to replicate \n // and place it after .container\n\n const vimeoID = '76979871';\n const YTubeID = 'bTqVqk7FSmY';\n const MP3url = ' https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.mp3';\n const OGGurl = 'https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.ogg';\n const MP4url = 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-720p.mp4';\n\n\n var htmlLitPage;\n\n if (button.id === 'doMP4') {\n\n htmlLitPage = `\n \n <video id=\"demoMP4\" class=\"pm links\" controls crossorigin playsinline\n <source src=\"${MP4url}\" type=\"video/mp4\">\n <!-- Fallback for browsers that don't support the <video> element -->\n <a href=\"${MP4url}\" download>Download</a>\n </video>\n\n `;\n\n }\n\n else if (button.id === 'doMP3') {\n\n htmlLitPage = `\n \n <audio id=\"demoMP3\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${MP3url}\" type=\"audio/mp3\">\n </audio>\n\n `;\n\n }\n\n else if (button.id === 'doOGG') {\n\n htmlLitPage = `\n \n <audio id=\"demoOGG\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${OGGurl}\" type=\"audio/ogg\">\n </audio>\n\n\n `;\n\n\n }\n\n else if (button.id === 'doVimeo') {\n\n htmlLitPage = `\n <div id=\"demoVimeo\" class=\"pm links\" data-plyr-provider=\"vimeo\" data-plyr-embed-id=\"76979871\"></div>\n `;\n\n\n }\n\n else if (button.id === 'doYT') {\n\n htmlLitPage = `\n <div id=\"demoYouTuibe\" class=\"pm links\" data-plyr-provider=\"youtube\" data-plyr-embed-id=\"bTqVqk7FSmY\"></div>\n `;\n\n\n }\n\n\n // for the textbox (user's code) need to remove the links class\n\n var htmlLitTextBox = htmlLitPage.replace(' links', '');\n\n\n // document.querySelector(\"body\").insertAdjacentHTML('beforeend', htmlLitPage);\n\n //#region 1 Mar \n // document.querySelector(\"body\").insertAdjacentHTML('beforeend', htmlLitPage);\n\n document.querySelector(\".container\").insertAdjacentHTML('beforeend', htmlLitPage);\n //#endregion\n\n\n // add disabled text box to display link code\n var vidDivDisplay = document.querySelector(\"#vidDivDisplay\");\n\n vidDivDisplay.value = htmlLitTextBox;\n\n vidDivDisplay.parentNode.style.display = \"block\";\n\n\n // add button to copy loop link code \n\n // onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#demo76979871_linkDiv > input[type=text]').value);})()\n\n var vidDivCopyButtonLit = `<input id=\"copyVidDiv\" type=\"button\" onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#vidDivDisplay').value);})()\" value=\"Copy Video Div\">`;\n\n vidDivDisplay.insertAdjacentHTML('afterend', vidDivCopyButtonLit);\n\n\n // start practisemaster\n this.player();\n\n event.preventDefault();\n\n },\n\n false\n )\n );\n\n }\n\n\n addDoITButtonListener() {\n\n\n\n // 'submit' from the LoopBuilder form\n\n const button = document.querySelector(\"#doIt\");\n\n button.addEventListener(\n \"click\",\n (event) => {\n //create new div to replicate \n // and place it after .container\n const radioButtons = document.querySelectorAll('input[name=\"source\"]');\n const vidID = document.querySelector('#providerVidID').value;\n\n const sourceURL = document.querySelector('#sourceURL').value;\n\n\n let choice;\n\n for (const radioButton of radioButtons) {\n if (radioButton.checked) {\n choice = radioButton.value;\n break;\n }\n }\n\n var htmlLitPage;\n\n if (choice === 'MP4') {\n\n htmlLitPage = `\n \n <video id=\"demoMP4\" class=\"pm links\" controls crossorigin playsinline>\n <source src=\"${sourceURL}\" type=\"video/mp4\">\n <!-- Fallback for browsers that don't support the <video> element -->\n <a href=\"${sourceURL}\" download>Download</a>\n </video>\n\n `;\n\n }\n\n else if (choice === 'MP3') {\n\n htmlLitPage = `\n \n <audio id=\"demoMP3\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${sourceURL}\" type=\"audio/mp3\">\n </audio>\n\n `;\n\n }\n\n else if (choice === 'OGG') {\n\n htmlLitPage = `\n \n <audio id=\"demoOGG\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${sourceURL}\" type=\"audio/ogg\">\n </audio>\n\n\n `;\n\n\n }\n\n else {\n\n htmlLitPage = `\n <div id=\"demo${vidID}\" class=\"pm links\" data-plyr-provider=\"${choice}\" data-plyr-embed-id=\"${vidID}\"></div>\n `;\n\n }\n\n\n // for the textbox (user's code) need to remove the links class\n\n var htmlLitTextBox = htmlLitPage.replace(' links', '');\n\n\n //#region 1 Mar \n // document.querySelector(\"body\").insertAdjacentHTML('beforeend', htmlLitPage);\n\n document.querySelector(\".container\").insertAdjacentHTML('beforeend', htmlLitPage);\n //#endregion\n\n\n // add disabled text box to display link code\n var vidDivDisplay = document.querySelector(\"#vidDivDisplay\");\n\n vidDivDisplay.value = htmlLitTextBox;\n\n vidDivDisplay.parentNode.style.display = \"block\";\n\n\n // add button to copy loop link code \n\n // onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#demo76979871_linkDiv > input[type=text]').value);})()\n\n var vidDivCopyButtonLit = `<input id=\"copyVidDiv\" type=\"button\" onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#vidDivDisplay').value);})()\" value=\"Copy Video Div\">`;\n\n vidDivDisplay.insertAdjacentHTML('afterend', vidDivCopyButtonLit);\n\n\n // start practisemaster\n this.player();\n\n event.preventDefault();\n\n },\n\n false\n );\n\n }\n}\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (PractiseMaster);\n\n//# sourceURL=webpack://practisemaster/./src/modules/practisemaster-pm.js?");
|
|
225
|
+
eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var _player_pm__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./player-pm */ \"./src/modules/player-pm.js\");\n/* harmony import */ var _pageSupport_pm__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./pageSupport-pm */ \"./src/modules/pageSupport-pm.js\");\n/**\n * module allows for the newing of a PractiseMaster class \n * a global window.PractiseMaster is created\n * \n * @module PractiseMaster Module\n * @requires Player Module\n * @requires PageSupport Module\n */\n\n\n\n\n\n/**\n * entry point for PractiseMaster js plugin: new PractiseMaster();\n * @class PractiseMaster\n * @property {mehtod} globals() - returns window.PractiseMaster\n * @property {method} player() - news up a Player class for each pm class element\n * @property {declaration} getElementsByClassName(\"pm\") - Elements to update with a player \n * @property {declaration} getElementsByClassName(\"pmlinkbuilder\") - Elements to update with a player \n * @property {class} PageSupport(siteCSS) - news this up with any site specific css\n * @property {object} siteCSS - an object for css specific to the host site (ex WordPress)\n */\n\nclass PractiseMaster {\n\n constructor(siteCSS) {\n\n this.globals();\n\n this.pmElements = document.getElementsByClassName(\"pm\");\n\n this.linkBuilderElements = document.getElementsByClassName(\"pmlinkbuilder\");\n\n Array.from(this.linkBuilderElements).forEach(el => {\n\n this.addLinkBuilderHTML(el);\n this.startLinkBuilder();\n\n });\n\n // site (ex WordPress css) goes on page once with PageSupport\n this.PageSupport = new _pageSupport_pm__WEBPACK_IMPORTED_MODULE_1__[\"default\"](siteCSS);\n\n this.player();\n\n this.siteCSS = siteCSS;\n\n }\n\n\n\n /**\n * instantiates any global variables from the PractiseMaster class\n * @method\n */\n\n globals() {\n\n window.PractiseMaster = this;\n\n }\n\n\n\n /**\n * news-up a Player class for each of [PMelements]\n * @method\n */\n\n player() {\n\n console.log(this.pmElements.length + \" 'pm' video or audio players created\");\n\n Array.from(this.pmElements).forEach((el) => {\n // Do stuff here\n console.log(el.tagName);\n\n this[\"PM_\" + el.id] = new _player_pm__WEBPACK_IMPORTED_MODULE_0__[\"default\"](el);\n\n });\n\n }\n\n\n\n /**\n * adds LinkBuilder form and tutorial HTML to DOM\n * @method\n * @param {Element} el eleent with pmlinkbuilder class\n */\n\n addLinkBuilderHTML(el) {\n\n el.insertAdjacentHTML('afterbegin',\n\n `\n <h1>PractiseMaster Precision Link Builder</h1>\n <br>\n <br>\n <br>\n\n <h2> Build loops and copy video embed html:</h2>\n\n <h3> Step 0:</h3>\n <div>If you need to:</div><button id=\"refresh\" onclick=\"location.reload();\">Start Again</button>\n\n <h3> Step 1:</h3>\n \n <fieldset>\n <legend>Please select your preferred video/audio source:</legend>\n <div>\n <input type=\"radio\" id=\"source1\" name=\"source\" value=\"vimeo\" />\n <label for=\"source1\">Vimeo</label>\n <input type=\"radio\" id=\"source2\" name=\"source\" value=\"youtube\" />\n <label for=\"source2\">YouTube</label>\n \n </div>\n <label for=\"providerVidID\">YouTube or Vimeo ID</label>\n <input id=\"providerVidID\" type=\"text\">\n <div>\n <br> \n <div>\n <input type=\"radio\" id=\"source3\" name=\"source\" value=\"MP4\" />\n <label for=\"source3\">MP4</label>\n <input type=\"radio\" id=\"source4\" name=\"source\" value=\"MP3\" />\n <label for=\"source4\">MP3</label>\n <input type=\"radio\" id=\"source3\" name=\"source\" value=\"OGG\" />\n <label for=\"source3\">OGG</label>\n </div>\n <label for=\"sourceURL\">Hosted Source</label>\n <input id=\"sourceURL\" type=\"text\"> (Public URL)\n <div>\n <br>\n <button id=\"doIt\">Start Video</button>\n </div>\n <br>\n <br>\n <fieldset>\n <div>\n If you need sources to try:\n <ul>\n <li>Vimeo: 76979871 <button class=\"demoButton\" id=\"doVimeo\">Start Vimeo</button>\n <li>YouTube: bTqVqk7FSmY <button class=\"demoButton\" id=\"doYT\">Start YouTube</button>\n <li>MP4 Video: https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-720p.mp4 <button class=\"demoButton\" id=\"doMP4\">Start MP4</button>\n <li>MP3 Audio: https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.mp3 <button class=\"demoButton\" id=\"doMP3\">Start MP3</button>\n <li>OGG Audio: https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.ogg <button class=\"demoButton\" id=\"doOGG\">Start OGG</button>\n </ul>\n </div>\n </fieldset>\n </fieldset>\n \n\n\n <div id=\"copyInputDiv\"style=\"display: none;\" >\n\n <br>\n <br>\n <br>\n\n <h2 id=\"step2\"> Step 2: Copy video embed </h2>\n <label for=\"vidDivDisplay\">Video Embed</label><input style=\"width: -webkit-fill-available;\" id=\"vidDivDisplay\" disabled >\n \n\n <br>\n <br>\n <br>\n <h1>Step 3: Build Loops (<svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"fak\" data-icon=\"light-link-circle-arrow-down\" role=\"img\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 610 510\" class=\"uploaded-icon-preview svg-inline--fa fa-light-link-circle-arrow-down\" style=\"width: 31px;height: 22px;\"><path fill=\"currentColor\" d=\"M173 131.4c49.1-49.9 130.9-49.9 180.8 0c26.2 26.2 38.5 61 37 95.5c-28 20.9-49.6 50-61.2 83.7c-4.2-5.8-4-14 .9-19.8c1.8-2.1 3.6-4.1 5.4-6.2c32.9-38 30.9-95-4.7-130.5c-37.4-37.5-98.1-37.5-135.5 0c-41.5 41.5-83.1 83-124.6 124.5c-37.5 37.5-37.5 98.3 0 135.8c37.5 37.5 98.3 37.5 135.8 0c7.5-7.5 15.1-15.1 22.6-22.6c6.2-6.3 16.4-6.3 22.6 0c6.3 6.2 6.3 16.3 0 22.6c-7.5 7.5-15.1 15.1-22.6 22.6c-50 50-131 50-181 0s-50-131.9 0-181c41.5-41.5 83-83.1 124.5-124.6zM286.2 380.6c-47.5-47.5-50.2-123.5-7.1-174.2c2.1-2 4.1-4.1 6.2-6.1c5.8-6.7 15.9-7.4 22.6-1.6c6.6 5.7 7.4 15.8 1.6 22.5c-1.8 2.1-3.6 4.1-5.4 6.2c-32.9 38-30.9 95 4.7 130.5c3.5 3.5 7.3 6.8 11.2 9.6c0 .2 0 .3 0 .5c0 13.4 1.5 26.4 4.3 38.9c-13.8-6.2-26.8-15-38.1-26.3zm282.7-283c-37.5-37.5-98.3-37.5-135.8 0c-7.5 7.5-15.1 15.1-22.6 22.6c-6.2 6.3-16.4 6.3-22.6 0c-6.3-7.1-6.3-16.3 0-22.6c7.5-7.5 15.1-15.1 22.6-22.6c50-50 131-50 181 0c43.2 42.4 49.1 109.2 17.7 158.3c-8.1-6.8-16.8-12.9-26-18.1c22.3-36.9 17.6-85.7-14.3-117.5zM496 480c40 0 77-21.3 97-56s20-77.3 0-112s-57-56-97-56s-77 21.3-97 56s-20 77.3 0 112s57 56 97 56zm0-256c51.4 0 99 27.4 124.7 72s25.7 99.4 0 144S547.4 512 496 512s-99-27.4-124.7-72s-25.7-99.4 0-144s73.3-72 124.7-72zm67.3 163.3l-56 56c-6.2 6.3-16.4 6.3-22.6 0c-18.7-18.7-37.3-37.3-56-56c-6.2-6.2-6.2-16.4 0-22.6s16.4-6.2 22.6 0c9.6 9.6 19.1 19.1 28.7 28.7c0-29.8 0-59.6 0-89.4c0-8.8 7.2-16 16-16s16 7.2 16 16c0 29.8 0 59.6 0 89.4c9.6-9.6 19.1-19.1 28.7-28.7c6.2-6.2 16.4-6.2 22.6 0s6.2 16.4 0 22.6z\" class=\"\"></path></svg>).</h1>\n <h3>Your Links Appear Below Video</h3>\n <br>\n <br>\n <br>\n </div>\n \n \n <div class=\"container\" style=\"max-width: 75%;\"></div>\n \n \n \n `\n );\n\n }\n\n\n\n /**\n * event listener for #doIt button\n * adds disabled text box and copy button and calls this.player()\n * @method\n */\n\n startLinkBuilder() {\n\n this.addDoITButtonListener();\n this.addDoDemosButtonListener();\n\n }\n\n addDoDemosButtonListener() {\n\n\n\n // 'submit' from the LoopBuilder form\n\n const buttons = document.querySelectorAll(\"button.demoButton\");\n\n buttons.forEach(button =>\n\n button.addEventListener(\n \"click\",\n (event) => {\n //create new div to replicate \n // and place it after .container\n\n const vimeoID = '76979871';\n const YTubeID = 'bTqVqk7FSmY';\n const MP3url = ' https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.mp3';\n const OGGurl = 'https://cdn.plyr.io/static/demo/Kishi_Bashi_-_It_All_Began_With_a_Burst.ogg';\n const MP4url = 'https://cdn.plyr.io/static/demo/View_From_A_Blue_Moon_Trailer-720p.mp4';\n\n\n var htmlLitPage;\n\n if (button.id === 'doMP4') {\n\n htmlLitPage = `\n \n <video id=\"demoMP4\" class=\"pm links\" controls crossorigin playsinline\n <source src=\"${MP4url}\" type=\"video/mp4\">\n <!-- Fallback for browsers that don't support the <video> element -->\n <a href=\"${MP4url}\" download>Download</a>\n </video>\n\n `;\n\n }\n\n else if (button.id === 'doMP3') {\n\n htmlLitPage = `\n \n <audio id=\"demoMP3\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${MP3url}\" type=\"audio/mp3\">\n </audio>\n\n `;\n\n }\n\n else if (button.id === 'doOGG') {\n\n htmlLitPage = `\n \n <audio id=\"demoOGG\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${OGGurl}\" type=\"audio/ogg\">\n </audio>\n\n\n `;\n\n\n }\n\n else if (button.id === 'doVimeo') {\n\n htmlLitPage = `\n <div id=\"demoVimeo\" class=\"pm links\" data-plyr-provider=\"vimeo\" data-plyr-embed-id=\"76979871\"></div>\n `;\n\n\n }\n\n else if (button.id === 'doYT') {\n\n htmlLitPage = `\n <div id=\"demoYouTuibe\" class=\"pm links\" data-plyr-provider=\"youtube\" data-plyr-embed-id=\"bTqVqk7FSmY\"></div>\n `;\n\n\n }\n\n\n // for the textbox (user's code) need to remove the links class\n\n var htmlLitTextBox = htmlLitPage.replace(' links', '');\n\n\n // document.querySelector(\"body\").insertAdjacentHTML('beforeend', htmlLitPage);\n\n //#region 1 Mar \n // document.querySelector(\"body\").insertAdjacentHTML('beforeend', htmlLitPage);\n\n document.querySelector(\".container\").insertAdjacentHTML('beforeend', htmlLitPage);\n //#endregion\n\n\n // add disabled text box to display link code\n var vidDivDisplay = document.querySelector(\"#vidDivDisplay\");\n\n vidDivDisplay.value = htmlLitTextBox;\n\n vidDivDisplay.parentNode.style.display = \"block\";\n\n\n // add button to copy loop link code \n\n // onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#demo76979871_linkDiv > input[type=text]').value);})()\n\n var vidDivCopyButtonLit = `<input id=\"copyVidDiv\" type=\"button\" onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#vidDivDisplay').value);})()\" value=\"Copy Video Div\">`;\n\n vidDivDisplay.insertAdjacentHTML('afterend', vidDivCopyButtonLit);\n\n\n // start practisemaster\n this.player();\n\n event.preventDefault();\n\n // scroll to step 2 for the user\n document.querySelector('#step2').scrollIntoView({behavior: 'smooth'});\n\n },\n\n false\n )\n );\n\n }\n\n\n addDoITButtonListener() {\n\n\n\n // 'submit' from the LoopBuilder form\n\n const button = document.querySelector(\"#doIt\");\n\n button.addEventListener(\n \"click\",\n (event) => {\n //create new div to replicate \n // and place it after .container\n const radioButtons = document.querySelectorAll('input[name=\"source\"]');\n const vidID = document.querySelector('#providerVidID').value;\n\n const sourceURL = document.querySelector('#sourceURL').value;\n\n\n let choice;\n\n for (const radioButton of radioButtons) {\n if (radioButton.checked) {\n choice = radioButton.value;\n break;\n }\n }\n\n var htmlLitPage;\n\n if (choice === 'MP4') {\n\n htmlLitPage = `\n \n <video id=\"demoMP4\" class=\"pm links\" controls crossorigin playsinline>\n <source src=\"${sourceURL}\" type=\"video/mp4\">\n <!-- Fallback for browsers that don't support the <video> element -->\n <a href=\"${sourceURL}\" download>Download</a>\n </video>\n\n `;\n\n }\n\n else if (choice === 'MP3') {\n\n htmlLitPage = `\n \n <audio id=\"demoMP3\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${sourceURL}\" type=\"audio/mp3\">\n </audio>\n\n `;\n\n }\n\n else if (choice === 'OGG') {\n\n htmlLitPage = `\n \n <audio id=\"demoOGG\" class=\"pm links\" crossorigin playsinline>\n <source src=\"${sourceURL}\" type=\"audio/ogg\">\n </audio>\n\n\n `;\n\n\n }\n\n else {\n\n htmlLitPage = `\n <div id=\"demo${vidID}\" class=\"pm links\" data-plyr-provider=\"${choice}\" data-plyr-embed-id=\"${vidID}\"></div>\n `;\n\n }\n\n\n // for the textbox (user's code) need to remove the links class\n\n var htmlLitTextBox = htmlLitPage.replace(' links', '');\n\n\n //#region 1 Mar \n // document.querySelector(\"body\").insertAdjacentHTML('beforeend', htmlLitPage);\n\n document.querySelector(\".pmlinkbuilder\").insertAdjacentHTML('beforeend', htmlLitPage);\n //#endregion\n\n\n // add disabled text box to display link code\n var vidDivDisplay = document.querySelector(\"#vidDivDisplay\");\n\n vidDivDisplay.value = htmlLitTextBox;\n\n vidDivDisplay.parentNode.style.display = \"block\";\n\n\n // add button to copy loop link code \n\n // onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#demo76979871_linkDiv > input[type=text]').value);})()\n\n var vidDivCopyButtonLit = `<input id=\"copyVidDiv\" type=\"button\" onclick=\"((event) => {navigator.clipboard.writeText(document.querySelector('#vidDivDisplay').value);})()\" value=\"Copy Video Div\">`;\n\n vidDivDisplay.insertAdjacentHTML('afterend', vidDivCopyButtonLit);\n\n\n // start practisemaster\n this.player();\n\n event.preventDefault();\n\n // scroll to step 2 for the user\n document.querySelector('#step2').scrollIntoView({behavior: 'smooth'});\n\n },\n\n false\n );\n\n }\n}\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (PractiseMaster);\n\n//# sourceURL=webpack://practisemaster/./src/modules/practisemaster-pm.js?");
|
|
226
226
|
|
|
227
227
|
/***/ }),
|
|
228
228
|
|
package/package.json
CHANGED
package/nonobfs/PMwrapper.js
DELETED