mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-06 03:50:04 +02:00
Update
This commit is contained in:
parent
3654d90b63
commit
5aaafd70ff
2 changed files with 30 additions and 1 deletions
|
@ -7200,6 +7200,11 @@ function getTourHelpButton($stepsFileRelativePath, $class = 'btn btn-default'){
|
|||
return "<button class=\"startTourBtn {$class}\" onclick=\"startTour('{$stepsFileRelativePath}')\"><i class=\"fa-solid fa-circle-question\"></i> ".__('Help')."</button>";
|
||||
}
|
||||
|
||||
function getInfoButton($info){
|
||||
$html = '<button class="btn btn-default btn-block infoButton" data-toggle="tooltip" title="'.__('Info').'"><i class="fa-solid fa-circle-info"></i><div class="hidden">'.$info.'</div></button>';
|
||||
return $html;
|
||||
}
|
||||
|
||||
require_once __DIR__.'/functionsSecurity.php';
|
||||
require_once __DIR__.'/functionsMySQL.php';
|
||||
require_once __DIR__.'/functionsDocker.php';
|
||||
|
|
|
@ -2954,6 +2954,10 @@ $(document).ready(function () {
|
|||
_alertFromGet('success');
|
||||
_alertFromGet('toast');
|
||||
|
||||
$(".infoButton").click(function() {
|
||||
var innerDiv = $(this).find("div.hidden");
|
||||
avideoAlertInfo(innerDiv.html());
|
||||
});
|
||||
});
|
||||
|
||||
/*!
|
||||
|
@ -4287,3 +4291,23 @@ function startTour(stepsFileRelativePath) {
|
|||
});
|
||||
}
|
||||
}
|
||||
|
||||
function findIndex(value, array) {
|
||||
return array.indexOf(value);
|
||||
}
|
||||
|
||||
function getNextValue(value, array) {
|
||||
const index = findIndex(value, array);
|
||||
if (index !== -1 && index < array.length - 1) {
|
||||
return array[index + 1];
|
||||
}
|
||||
return null; // Return null if there is no next value
|
||||
}
|
||||
|
||||
function getPreviousValue(value, array) {
|
||||
const index = findIndex(value, array);
|
||||
if (index > 0) {
|
||||
return array[index - 1];
|
||||
}
|
||||
return null; // Return null if there is no previous value
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue