Commit 971dcb51 authored by Ahoy's avatar Ahoy

offsetHeight, N player

parent 4d5d2358
Pipeline #17529088 failed with stages
in 43 seconds
......@@ -239,6 +239,9 @@
<br>
<span class="attr-name">data-button=&quot;</span><span class="attr-value">moonwalk: Плеер онлайн, hdgo: Запас. плеер</span><span class="attr-name">&quot;</span>
<span class="comment"> - названия кнопок</span>
<br>
<span class="attr-name">data-button=&quot;</span><span class="attr-value">moonwalk: Плеер {N}, hdgo: Плеер {N}</span><span class="attr-name">&quot;</span>
<span class="comment"> - можно использовать нумерацию {N}, будет указана цифра плеера</span>
</div>
<div class="code">
<span class="comment">
......
......@@ -131,7 +131,15 @@ function yo(sel) {
w = 610;
}
if (parseInt(yohoho.offsetHeight) && w/3 < parseInt(yohoho.offsetHeight)) {
if (parseInt(yohoho.offsetHeight) && parseInt(yohoho.offsetHeight) < 370) {
if (parseInt(yohoho.parentNode.offsetHeight) && parseInt(yohoho.parentNode.offsetHeight) >= 370) {
h = parseInt(yohoho.parentNode.offsetHeight);
}
else {
h = 370;
}
}
else if (parseInt(yohoho.offsetHeight) && w/3 < parseInt(yohoho.offsetHeight)) {
h = parseInt(yohoho.offsetHeight);
}
else if (parseInt(yohoho.parentNode.offsetHeight) && w/3 < parseInt(yohoho.parentNode.offsetHeight)) {
......@@ -179,6 +187,7 @@ function yo(sel) {
option.dataset.iframe = players[key];
if (btns.hasOwnProperty(key) && btns[key]) {
j++;
btns[key] = btns[key].replace('{N}', j);
option.innerText = j + '► ' + btns[key];
}
else if (key === 'trailer') {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment