update
This commit is contained in:
parent
516821801a
commit
6aa6eea1c6
Binary file not shown.
@ -258,23 +258,20 @@
|
|||||||
function createDragItems() {
|
function createDragItems() {
|
||||||
const container = $("#content-drags");
|
const container = $("#content-drags");
|
||||||
container.empty();
|
container.empty();
|
||||||
const dragMapping = {
|
const dragItems = [
|
||||||
"Zona interna del conector a paciente": 0,
|
{ text: "Zona interna del conector a paciente", value: 0 },
|
||||||
"Punta abierta en la línea de transferencia": 1,
|
{ text: "Punta abierta en la línea de transferencia", value: 1 },
|
||||||
"Cassette en DPA": 2,
|
{ text: "Cassette en DPA", value: 2 },
|
||||||
"Parte interna del tapón minicap": 3,
|
{ text: "Parte interna del tapón minicap", value: 3 },
|
||||||
};
|
];
|
||||||
questions.forEach((question, index) => {
|
dragItems.forEach((item) => {
|
||||||
question.opciones.forEach((opcion, opcionIndex) => {
|
|
||||||
const dragValue = dragMapping[opcion.text] !== undefined ? dragMapping[opcion.text] : 0;
|
|
||||||
const dragItem = `
|
const dragItem = `
|
||||||
<div class="drag-item px-3 py-2 bg-verde-claro-2 text-verde-oscuro fw-bold bx-shadow" data-drag="${dragValue}">
|
<div class="drag-item px-3 py-2 bg-verde-claro-2 text-verde-oscuro fw-bold bx-shadow text-center" data-drag="${item.value}">
|
||||||
<div class="d-flex flex-row justify-content-center align-items-center w-100 h-100"><div>${opcion.text}</div></div>
|
<div class="d-flex flex-row justify-content-center align-items-center w-100 h-100"><div>${item.text}</div></div>
|
||||||
</div>
|
</div>
|
||||||
`;
|
`;
|
||||||
container.append(dragItem);
|
container.append(dragItem);
|
||||||
});
|
});
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function createDropItems() {
|
function createDropItems() {
|
||||||
|
|||||||
@ -85,7 +85,7 @@
|
|||||||
.btn-answer {
|
.btn-answer {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
box-shadow: 0 0 2px rgba(0, 0, 0, .5);
|
box-shadow: 0 0 2px rgba(0, 0, 0, 0.5);
|
||||||
background-color: #f8f9fa;
|
background-color: #f8f9fa;
|
||||||
color: #333;
|
color: #333;
|
||||||
}
|
}
|
||||||
@ -117,15 +117,15 @@
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
<div id="inicio" class='page-sco py-2 py-md-0 h-100'>
|
<div id="inicio" class="page-sco py-2 py-md-0 h-100">
|
||||||
<div class='container h-100'>
|
<div class="container h-100">
|
||||||
<div class='row justify-content-center align-items-center h-100'>
|
<div class="row justify-content-center align-items-center h-100">
|
||||||
<div class='col-11'>
|
<div class="col-11">
|
||||||
<div class='row justify-content-center align-items-center'>
|
<div class="row justify-content-center align-items-center">
|
||||||
<div class="col-12 text-center animate__animated animate__bounceInDown">
|
<div class="col-12 text-center animate__animated animate__bounceInDown">
|
||||||
<div class="position-relative d-inline-block">
|
<div class="position-relative d-inline-block">
|
||||||
<h2 class="text-primary mb-1 fw-bold">Autocuidado</h2>
|
<h2 class="text-primary mb-1 fw-bold">Autocuidado</h2>
|
||||||
<hr class="border border-2 border-verde-oscuro hr-style my-0 mb-1 opacity-100">
|
<hr class="border border-2 border-verde-oscuro hr-style my-0 mb-1 opacity-100" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 mb-3 text-center">
|
<div class="col-12 mb-3 text-center">
|
||||||
@ -133,37 +133,42 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col-5 text-center mb-3 animate__animated animate__flipInX">
|
<div class="col-5 text-center mb-3 animate__animated animate__flipInX">
|
||||||
<div class="card bg-white border-0 rounded-3 p-3 pb-0 bx-shadow">
|
<div class="card bg-white border-0 rounded-3 p-3 pb-0 bx-shadow">
|
||||||
<p><b class="text-lila-claro">La alimentación</b> balanceada es muy importante. Como parte de su
|
<p>
|
||||||
tratamiento <b class="text-lila-claro">se debe personalizar</b> con base en sus necesidades.</p>
|
<b class="text-lila-claro">La alimentación</b> balanceada es muy importante. Como
|
||||||
<p>También, es necesario <strong class="text-lila-claro">mantener un estilo de vida activo </strong>para
|
parte de su tratamiento <b class="text-lila-claro">se debe personalizar</b> con base
|
||||||
el
|
en sus necesidades.
|
||||||
buen funcionamiento de músculos,
|
</p>
|
||||||
huesos y corazón.</p>
|
<p>
|
||||||
|
También, es necesario
|
||||||
|
<strong class="text-lila-claro">mantener un estilo de vida activo </strong>para el
|
||||||
|
buen funcionamiento de músculos, huesos y corazón.
|
||||||
|
</p>
|
||||||
<div class="w-100 position-relative text-center">
|
<div class="w-100 position-relative text-center">
|
||||||
<div
|
<div
|
||||||
class="btn-comenzar bg-primary d-inline-block px-3 py-2 text-center animate__animated animate__pulse animate__infinite">
|
class="btn-comenzar bg-primary d-inline-block px-3 py-2 text-center animate__animated animate__pulse animate__infinite"
|
||||||
|
>
|
||||||
<h5 class="text-white fw-bold mb-0">COMENZAR ACTIVIDAD</h5>
|
<h5 class="text-white fw-bold mb-0">COMENZAR ACTIVIDAD</h5>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-4 text-center mb-1 animate__animated animate__zoomIn">
|
<div class="col-4 text-center mb-1 animate__animated animate__zoomIn">
|
||||||
<img src="img/12.0.png" class="img-fluid">
|
<img src="img/12.0.png" class="img-fluid" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="desarrollo" class='page-sco py-2 py-md-0 h-100' style="display: none;overflow: hidden;">
|
<div id="desarrollo" class="page-sco py-2 py-md-0 h-100" style="display: none; overflow: hidden">
|
||||||
<div class='container h-100'>
|
<div class="container h-100">
|
||||||
<div class='row justify-content-center align-items-center h-100'>
|
<div class="row justify-content-center align-items-center h-100">
|
||||||
<div class='col-12'>
|
<div class="col-12">
|
||||||
<div class='row justify-content-center mb-5'>
|
<div class="row justify-content-center mb-5">
|
||||||
<div class="col-11 text-center animate__animated animate__bounceInDown">
|
<div class="col-11 text-center animate__animated animate__bounceInDown">
|
||||||
<div class="position-relative d-inline-block">
|
<div class="position-relative d-inline-block">
|
||||||
<h2 class="text-primary mb-1 fw-bold">Autocuidado</h2>
|
<h2 class="text-primary mb-1 fw-bold">Autocuidado</h2>
|
||||||
<hr class="border border-2 border-verde-oscuro hr-style my-0 mb-3 opacity-100">
|
<hr class="border border-2 border-verde-oscuro hr-style my-0 mb-3 opacity-100" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 mb-3 text-center">
|
<div class="col-12 mb-3 text-center">
|
||||||
@ -172,14 +177,25 @@
|
|||||||
<div class="col-12 px-0 mb-3">
|
<div class="col-12 px-0 mb-3">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-8">
|
<div class="col-8">
|
||||||
<div class="card bg-verde-claro border-0 bx-shadow py-2 px-3"
|
<div
|
||||||
style="border-radius: 15px;border-top-left-radius: 0;border-bottom-left-radius: 0;">
|
class="card bg-verde-claro border-0 bx-shadow py-2 px-3"
|
||||||
|
style="
|
||||||
|
border-radius: 15px;
|
||||||
|
border-top-left-radius: 0;
|
||||||
|
border-bottom-left-radius: 0;
|
||||||
|
"
|
||||||
|
>
|
||||||
<div class="row justify-content-start">
|
<div class="row justify-content-start">
|
||||||
<div class="col-12">
|
<div class="col-12">
|
||||||
<div class="d-flex flex-row justify-content-center align-items-center gap-3 ps-4">
|
<div
|
||||||
<img src="img/book1.png" class="img-fluid">
|
class="d-flex flex-row justify-content-center align-items-center gap-3 ps-4"
|
||||||
<p class="mb-0"><strong>Instrucciones:</strong> Dé clic en la ruleta y conteste correctamente la
|
>
|
||||||
pregunta acerca de su alimentación o actividad física para ganar los puntos.</p>
|
<img src="img/book1.png" class="img-fluid" />
|
||||||
|
<p class="mb-0">
|
||||||
|
<strong>Instrucciones:</strong> Dé clic en la ruleta y conteste
|
||||||
|
correctamente la pregunta acerca de su alimentación o actividad física
|
||||||
|
para ganar los puntos.
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -188,7 +204,9 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-11">
|
<div class="col-11">
|
||||||
<div class="row justify-content-center align-items-center animate__animated animate__slideInRight">
|
<div
|
||||||
|
class="row justify-content-center align-items-center animate__animated animate__slideInRight"
|
||||||
|
>
|
||||||
<div class="col-6">
|
<div class="col-6">
|
||||||
<div class="card custom-card bg-secondary border-0 shadow">
|
<div class="card custom-card bg-secondary border-0 shadow">
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
@ -203,14 +221,29 @@
|
|||||||
<img src="img/progress.png" alt="" class="img-fluid" />
|
<img src="img/progress.png" alt="" class="img-fluid" />
|
||||||
<div
|
<div
|
||||||
class="wavance position-absolute d-flex flex-row align-items-center justify-content-start w-100"
|
class="wavance position-absolute d-flex flex-row align-items-center justify-content-start w-100"
|
||||||
style="top: 22%">
|
style="top: 22%"
|
||||||
<div class="avance"><img src="img/pr.png" class="img-fluid" alt="" /></div>
|
>
|
||||||
<div class="avance"><img src="img/pr.png" class="img-fluid" alt="" /></div>
|
<div class="avance">
|
||||||
<div class="avance"><img src="img/pr.png" class="img-fluid" alt="" /></div>
|
<img src="img/pr.png" class="img-fluid" alt="" />
|
||||||
<div class="avance"><img src="img/pr.png" class="img-fluid" alt="" /></div>
|
</div>
|
||||||
<div class="avance"><img src="img/pr.png" class="img-fluid" alt="" /></div>
|
<div class="avance">
|
||||||
<div class="avance"><img src="img/pr.png" class="img-fluid" alt="" /></div>
|
<img src="img/pr.png" class="img-fluid" alt="" />
|
||||||
<div class="avance"><img src="img/pr.png" class="img-fluid" alt="" /></div>
|
</div>
|
||||||
|
<div class="avance">
|
||||||
|
<img src="img/pr.png" class="img-fluid" alt="" />
|
||||||
|
</div>
|
||||||
|
<div class="avance">
|
||||||
|
<img src="img/pr.png" class="img-fluid" alt="" />
|
||||||
|
</div>
|
||||||
|
<div class="avance">
|
||||||
|
<img src="img/pr.png" class="img-fluid" alt="" />
|
||||||
|
</div>
|
||||||
|
<div class="avance">
|
||||||
|
<img src="img/pr.png" class="img-fluid" alt="" />
|
||||||
|
</div>
|
||||||
|
<div class="avance">
|
||||||
|
<img src="img/pr.png" class="img-fluid" alt="" />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -221,18 +254,23 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-12 text-center">
|
<div class="col-12 text-center">
|
||||||
<div class="mt-3">
|
<div class="mt-3">
|
||||||
<button id="spin-btn"
|
<button
|
||||||
class="bg-verde-oscuro text-white border border-4 border-white animate__animated animate__pulse animate__infinite">¡GIRAR
|
id="spin-btn"
|
||||||
RULETA!</button>
|
class="bg-verde-oscuro text-white border border-4 border-white animate__animated animate__pulse animate__infinite"
|
||||||
|
>
|
||||||
|
¡GIRAR RULETA!
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-4 text-center" style="margin-top: -30px;">
|
<div class="col-4 text-center" style="margin-top: -30px">
|
||||||
<div class="card flat justify-content-center align-items-center d-inline-flex">
|
<div class="card flat justify-content-center align-items-center d-inline-flex">
|
||||||
<div class="indicador position-absolute start-50 translate-middle-x"
|
<div
|
||||||
style="z-index: 9999 !important; top: -1em">
|
class="indicador position-absolute start-50 translate-middle-x"
|
||||||
|
style="z-index: 9999 !important; top: -1em"
|
||||||
|
>
|
||||||
<img src="img/indicador.png" alt="" style="transform: rotate(90deg)" />
|
<img src="img/indicador.png" alt="" style="transform: rotate(90deg)" />
|
||||||
</div>
|
</div>
|
||||||
<div class="wruleta z-2" id="ruleta-wheel">
|
<div class="wruleta z-2" id="ruleta-wheel">
|
||||||
@ -247,18 +285,18 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="cierre" class='page-sco py-2 py-md-0 h-100' style="display: none;">
|
<div id="cierre" class="page-sco py-2 py-md-0 h-100" style="display: none">
|
||||||
<div class='container h-100'>
|
<div class="container h-100">
|
||||||
<div class='row justify-content-center align-items-center h-100'>
|
<div class="row justify-content-center align-items-center h-100">
|
||||||
<div class='col-12'>
|
<div class="col-12">
|
||||||
<div class="row justify-content-center">
|
<div class="row justify-content-center">
|
||||||
<div class="col-12 text-center mb-3">
|
<div class="col-12 text-center mb-3">
|
||||||
<img src="img/cierre_actividad.png" class="img-fluid">
|
<img src="img/cierre_actividad.png" class="img-fluid" />
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 mb-3 text-center">
|
<div class="col-12 mb-3 text-center">
|
||||||
<div class="position-relative d-inline-block">
|
<div class="position-relative d-inline-block">
|
||||||
<h2 class="text-primary mb-1 fw-bold">Autocuidado</h2>
|
<h2 class="text-primary mb-1 fw-bold">Autocuidado</h2>
|
||||||
<hr class="border border-2 border-verde-oscuro hr-style my-0 opacity-100">
|
<hr class="border border-2 border-verde-oscuro hr-style my-0 opacity-100" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 mb-3 text-center">
|
<div class="col-12 mb-3 text-center">
|
||||||
@ -267,10 +305,14 @@
|
|||||||
<div class="col-12 text-center mb-3">
|
<div class="col-12 text-center mb-3">
|
||||||
<h4 class="text-secondary fw-bold">Ha concluido la actividad.</h4>
|
<h4 class="text-secondary fw-bold">Ha concluido la actividad.</h4>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 text-center col-reintentar animate__animated animate__zoomIn" style="display: none;">
|
<div
|
||||||
|
class="col-12 text-center col-reintentar animate__animated animate__zoomIn"
|
||||||
|
style="display: none"
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
class="btn-reintentar rounded-3 bg-primary d-inline-block px-3 py-2 text-center animate__animated animate__pulse animate__infinite"
|
class="btn-reintentar rounded-3 bg-primary d-inline-block px-3 py-2 text-center animate__animated animate__pulse animate__infinite"
|
||||||
onclick="CourseNav.reload()">
|
onclick="CourseNav.reload()"
|
||||||
|
>
|
||||||
<h5 class="text-white fw-bold mb-0">Reintentar</h5>
|
<h5 class="text-white fw-bold mb-0">Reintentar</h5>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -282,7 +324,7 @@
|
|||||||
<script>
|
<script>
|
||||||
$(function () {
|
$(function () {
|
||||||
"use strict";
|
"use strict";
|
||||||
$('.wrap-course-content').addClass('fake');
|
$(".wrap-course-content").addClass("fake");
|
||||||
|
|
||||||
const puntajes = [100, 200, 300, 400, 500, 600, 700, 600, 500, 400, 300, 200];
|
const puntajes = [100, 200, 300, 400, 500, 600, 700, 600, 500, 400, 300, 200];
|
||||||
let isSpinning = false;
|
let isSpinning = false;
|
||||||
@ -299,12 +341,12 @@
|
|||||||
const bad = CourseNav.createSound("audio/feedback-incorrect.mpeg");
|
const bad = CourseNav.createSound("audio/feedback-incorrect.mpeg");
|
||||||
const good = CourseNav.createSound("audio/feedback-correct.mpeg");
|
const good = CourseNav.createSound("audio/feedback-correct.mpeg");
|
||||||
|
|
||||||
$('.btn-comenzar').click(function (e) {
|
$(".btn-comenzar").click(function (e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
CourseNav.soundClick();
|
CourseNav.soundClick();
|
||||||
$('.wrap-course-content').addClass('fake1').removeClass('fake');
|
$(".wrap-course-content").addClass("fake1").removeClass("fake");
|
||||||
$('#inicio').hide();
|
$("#inicio").hide();
|
||||||
$('#desarrollo').show();
|
$("#desarrollo").show();
|
||||||
});
|
});
|
||||||
|
|
||||||
function girarRuleta() {
|
function girarRuleta() {
|
||||||
@ -370,8 +412,12 @@
|
|||||||
return {
|
return {
|
||||||
pregunta: fila.pregunta.trim(),
|
pregunta: fila.pregunta.trim(),
|
||||||
opciones: opciones,
|
opciones: opciones,
|
||||||
retroalimentacion_correcta: fila.retroalimentacion_correcta ? fila.retroalimentacion_correcta.trim() : '',
|
retroalimentacion_correcta: fila.retroalimentacion_correcta
|
||||||
retroalimentacion_incorrecta: fila.retroalimentacion_incorrecta ? fila.retroalimentacion_incorrecta.trim() : ''
|
? fila.retroalimentacion_correcta.trim()
|
||||||
|
: "",
|
||||||
|
retroalimentacion_incorrecta: fila.retroalimentacion_incorrecta
|
||||||
|
? fila.retroalimentacion_incorrecta.trim()
|
||||||
|
: "",
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
return preguntas;
|
return preguntas;
|
||||||
@ -395,7 +441,7 @@
|
|||||||
questions.splice(indiceAleatorio, 1); // Eliminar la pregunta usada
|
questions.splice(indiceAleatorio, 1); // Eliminar la pregunta usada
|
||||||
const opcionesBarajadas = shuffleArray([...preguntaAleatoria.opciones]);
|
const opcionesBarajadas = shuffleArray([...preguntaAleatoria.opciones]);
|
||||||
|
|
||||||
let opcionesHTML = '';
|
let opcionesHTML = "";
|
||||||
opcionesBarajadas.forEach((opcion, index) => {
|
opcionesBarajadas.forEach((opcion, index) => {
|
||||||
opcionesHTML += `<div class="position-relative d-flex flex-row align-items-center gap-0 mb-2 btn-answer" data-correct="${opcion.correct}" data-puntos="${puntajeEnJuego}">
|
opcionesHTML += `<div class="position-relative d-flex flex-row align-items-center gap-0 mb-2 btn-answer" data-correct="${opcion.correct}" data-puntos="${puntajeEnJuego}">
|
||||||
<div class="d-flex flex-row justify-content-center align-items-center letter text-white text-center p-3">${String.fromCharCode(97 + index)}</div>
|
<div class="d-flex flex-row justify-content-center align-items-center letter text-white text-center p-3">${String.fromCharCode(97 + index)}</div>
|
||||||
@ -404,7 +450,7 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
Swal.fire({
|
Swal.fire({
|
||||||
target: document.getElementById('wrap-course-content'),
|
target: document.getElementById("wrap-course-content"),
|
||||||
html: `
|
html: `
|
||||||
<div class="text-center mb-3">
|
<div class="text-center mb-3">
|
||||||
<h4 class="fw-bold text-verde-oscuro">${preguntaAleatoria.pregunta}</h4>
|
<h4 class="fw-bold text-verde-oscuro">${preguntaAleatoria.pregunta}</h4>
|
||||||
@ -417,24 +463,24 @@
|
|||||||
showConfirmButton: false,
|
showConfirmButton: false,
|
||||||
allowOutsideClick: false,
|
allowOutsideClick: false,
|
||||||
customClass: {
|
customClass: {
|
||||||
popup: 'swal-wide bg-white border-0 rounded-3 shadow'
|
popup: "swal-wide bg-white border-0 rounded-3 shadow",
|
||||||
},
|
},
|
||||||
backdrop: "rgba(65, 60, 60, .95)",
|
backdrop: "rgba(65, 60, 60, .95)",
|
||||||
width: "50em",
|
width: "50em",
|
||||||
didOpen: () => {
|
didOpen: () => {
|
||||||
$('.btn-answer').click(function () {
|
$(".btn-answer").click(function () {
|
||||||
const isCorrect = $(this).data('correct') === true;
|
const isCorrect = $(this).data("correct") === true;
|
||||||
const puntos = $(this).data('puntos');
|
const puntos = $(this).data("puntos");
|
||||||
|
|
||||||
$('.btn-answer').off('click').css('pointer-events', 'none');
|
$(".btn-answer").off("click").css("pointer-events", "none");
|
||||||
|
|
||||||
if (isCorrect) {
|
if (isCorrect) {
|
||||||
$(this).addClass('bg-success text-white');
|
$(this).addClass("bg-success text-white");
|
||||||
totalPuntos += puntos;
|
totalPuntos += puntos;
|
||||||
actualizarPuntos(true);
|
actualizarPuntos(true);
|
||||||
} else {
|
} else {
|
||||||
actualizarPuntos(false);
|
actualizarPuntos(false);
|
||||||
$(this).addClass('bg-danger text-white');
|
$(this).addClass("bg-danger text-white");
|
||||||
//$('.btn-answer[data-correct="true"]').addClass('bg-success text-white');
|
//$('.btn-answer[data-correct="true"]').addClass('bg-success text-white');
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -445,28 +491,26 @@
|
|||||||
mostrarFeedback(isCorrect, preguntaAleatoria);
|
mostrarFeedback(isCorrect, preguntaAleatoria);
|
||||||
}, 500);
|
}, 500);
|
||||||
});
|
});
|
||||||
}
|
},
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function mostrarFeedback(isCorrect, pregunta) {
|
function mostrarFeedback(isCorrect, pregunta) {
|
||||||
const retroalimentacion = isCorrect ? pregunta.retroalimentacion_correcta : pregunta.retroalimentacion_incorrecta;
|
|
||||||
|
|
||||||
Swal.fire({
|
Swal.fire({
|
||||||
target: document.getElementById('wrap-course-content'),
|
target: document.getElementById("wrap-course-content"),
|
||||||
imageUrl: isCorrect ? 'img/good.png' : 'img/bad.png',
|
imageUrl: isCorrect ? "img/good.png" : "img/bad.png",
|
||||||
text: retroalimentacion || '',
|
|
||||||
showConfirmButton: true,
|
showConfirmButton: true,
|
||||||
customClass: {
|
customClass: {
|
||||||
popup: 'pop_retros bg-transparent border-0 rounded-0 shadow-none',
|
popup: "pop_retros bg-transparent border-0 rounded-0 shadow-none",
|
||||||
confirmButton: 'btn text-primary bg-lila-rosa amor fw-semibold animate__animated animate__pulse animate__infinite'
|
confirmButton:
|
||||||
|
"btn text-primary bg-lila-rosa amor fw-semibold animate__animated animate__pulse animate__infinite",
|
||||||
},
|
},
|
||||||
confirmButtonText: "Continuar",
|
confirmButtonText: "Continuar",
|
||||||
backdrop: "rgba(65, 60, 60, .95)",
|
backdrop: "rgba(65, 60, 60, .95)",
|
||||||
width: "35em",
|
width: "35em",
|
||||||
didClose: () => {
|
didClose: () => {
|
||||||
continuarJuego();
|
continuarJuego();
|
||||||
}
|
},
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -490,7 +534,7 @@
|
|||||||
puntosDisplay.textContent = totalPuntos;
|
puntosDisplay.textContent = totalPuntos;
|
||||||
|
|
||||||
if (isCorrect && avanceImages[girosRealizados]) {
|
if (isCorrect && avanceImages[girosRealizados]) {
|
||||||
avanceImages[girosRealizados].classList.add('visited');
|
avanceImages[girosRealizados].classList.add("visited");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -499,22 +543,20 @@
|
|||||||
const porcentaje = (totalPuntos / puntajeMaximo) * 100;
|
const porcentaje = (totalPuntos / puntajeMaximo) * 100;
|
||||||
const aprobado = porcentaje >= 80;
|
const aprobado = porcentaje >= 80;
|
||||||
|
|
||||||
$('.wrap-course-content').addClass('fake2').removeClass('fake1');
|
$(".wrap-course-content").addClass("fake2").removeClass("fake1");
|
||||||
|
|
||||||
CourseNav.setSlideVisited();
|
CourseNav.setSlideVisited();
|
||||||
|
|
||||||
if (aprobado) {
|
if (aprobado) {
|
||||||
$('#desarrollo').hide();
|
$("#desarrollo").hide();
|
||||||
$('#cierre').show();
|
$("#cierre").show();
|
||||||
} else {
|
} else {
|
||||||
$('.col-reintentar').show();
|
$(".col-reintentar").show();
|
||||||
$('#desarrollo').hide();
|
$("#desarrollo").hide();
|
||||||
$('#cierre').show();
|
$("#cierre").show();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
readExcelFile(urlExcelFile, function (data) {
|
readExcelFile(urlExcelFile, function (data) {
|
||||||
const hojaDatos = data["Diapositiva 24"];
|
const hojaDatos = data["Diapositiva 24"];
|
||||||
questions = shuffleArray(procesarPreguntas(hojaDatos));
|
questions = shuffleArray(procesarPreguntas(hojaDatos));
|
||||||
|
|||||||
@ -29,9 +29,8 @@
|
|||||||
.grip-jeopardy {
|
.grip-jeopardy {
|
||||||
position: relative;
|
position: relative;
|
||||||
width: 80%;
|
width: 80%;
|
||||||
display: grid;
|
display: flex;
|
||||||
grid-template-columns: repeat(4, 1fr);
|
flex-wrap: wrap;
|
||||||
grid-template-rows: repeat(2, 1fr);
|
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@ -41,6 +40,7 @@
|
|||||||
|
|
||||||
.btn-question-pop {
|
.btn-question-pop {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
flex: 0 0 calc(25% - 15px);
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-question-pop.completed {
|
.btn-question-pop.completed {
|
||||||
@ -196,7 +196,7 @@
|
|||||||
>
|
>
|
||||||
<img src="img/13.1.png" class="img-fluid" />
|
<img src="img/13.1.png" class="img-fluid" />
|
||||||
</div>
|
</div>
|
||||||
<div
|
<!-- <div
|
||||||
class="btn-question-pop animate__animated animate__pulse animate__infinite"
|
class="btn-question-pop animate__animated animate__pulse animate__infinite"
|
||||||
data-puntos="100"
|
data-puntos="100"
|
||||||
>
|
>
|
||||||
@ -213,7 +213,7 @@
|
|||||||
data-puntos="200"
|
data-puntos="200"
|
||||||
>
|
>
|
||||||
<img src="img/13.2.png" class="img-fluid" />
|
<img src="img/13.2.png" class="img-fluid" />
|
||||||
</div>
|
</div> -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -385,14 +385,9 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
function mostrarFeedback(isCorrect, pregunta, questionIndex) {
|
function mostrarFeedback(isCorrect, pregunta, questionIndex) {
|
||||||
const retroalimentacion = isCorrect
|
|
||||||
? pregunta.retroalimentacion_correcta
|
|
||||||
: pregunta.retroalimentacion_incorrecta;
|
|
||||||
|
|
||||||
Swal.fire({
|
Swal.fire({
|
||||||
target: document.getElementById("wrap-course-content"),
|
target: document.getElementById("wrap-course-content"),
|
||||||
imageUrl: isCorrect ? "img/good.png" : "img/bad.png",
|
imageUrl: isCorrect ? "img/good.png" : "img/bad.png",
|
||||||
text: retroalimentacion || "",
|
|
||||||
showConfirmButton: true,
|
showConfirmButton: true,
|
||||||
customClass: {
|
customClass: {
|
||||||
popup: "pop_retros bg-transparent border-0 rounded-0 shadow-none",
|
popup: "pop_retros bg-transparent border-0 rounded-0 shadow-none",
|
||||||
@ -436,7 +431,11 @@
|
|||||||
$(".btn-question-pop").click(function () {
|
$(".btn-question-pop").click(function () {
|
||||||
const index = $(this).index();
|
const index = $(this).index();
|
||||||
const puntosEnJuego = parseInt($(this).data("puntos"));
|
const puntosEnJuego = parseInt($(this).data("puntos"));
|
||||||
if (!$(this).hasClass("completed") && !$(this).hasClass("disabled")) {
|
if (
|
||||||
|
!$(this).hasClass("completed") &&
|
||||||
|
!$(this).hasClass("disabled") &&
|
||||||
|
index < questions.length
|
||||||
|
) {
|
||||||
$(this).removeClass("animate__pulse animate__infinite").addClass("disabled");
|
$(this).removeClass("animate__pulse animate__infinite").addClass("disabled");
|
||||||
CourseNav.soundClick();
|
CourseNav.soundClick();
|
||||||
mostrarPregunta(index, puntosEnJuego);
|
mostrarPregunta(index, puntosEnJuego);
|
||||||
@ -445,7 +444,8 @@
|
|||||||
|
|
||||||
readExcelFile(urlExcelFile, function (data) {
|
readExcelFile(urlExcelFile, function (data) {
|
||||||
const hojaDatos = data["Diapositiva 26"];
|
const hojaDatos = data["Diapositiva 26"];
|
||||||
questions = shuffleArray(procesarPreguntas(hojaDatos));
|
const todasLasPreguntas = shuffleArray(procesarPreguntas(hojaDatos));
|
||||||
|
questions = todasLasPreguntas.slice(0, 5);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
BIN
img/08.2.png
BIN
img/08.2.png
Binary file not shown.
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 33 KiB |
BIN
img/15.5.png
BIN
img/15.5.png
Binary file not shown.
|
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 32 KiB |
BIN
img/15.6.png
BIN
img/15.6.png
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 18 KiB |
Loading…
x
Reference in New Issue
Block a user