2023-01-10 22:39:11 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
use DarksLight2\Training\TrainingManager;
|
|
|
|
|
|
|
|
$short_name = 'first_step';
|
|
|
|
|
|
|
|
$manager = TrainingManager::getInstance();
|
2023-01-12 20:38:13 +00:00
|
|
|
$step = $manager->$short_name;
|
|
|
|
$button_text = 'Продолжить';
|
|
|
|
if(!$manager) {
|
|
|
|
$button_text = '';
|
|
|
|
}
|
|
|
|
?>
|
2023-01-10 22:39:11 +00:00
|
|
|
|
2023-01-12 20:38:13 +00:00
|
|
|
<script>
|
|
|
|
const training_data = () => {
|
|
|
|
return {
|
|
|
|
content: `<?=$step->message?>`,
|
|
|
|
title: `<?=$step->title?>`,
|
|
|
|
button_text: `<?=$button_text?>`
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
<script src="/js/training/modal.js"></script>
|
2023-01-10 22:39:11 +00:00
|
|
|
|
2023-01-12 20:38:13 +00:00
|
|
|
<script>
|
|
|
|
modal.show()
|
|
|
|
</script>
|