Files
Manual_Vantive/contenido/10.html
T

353 lines
13 KiB
HTML
Raw Normal View History

2025-10-06 11:13:23 -06:00
<style>
.fake {
background-image: url(img/bg00.jpg);
background-repeat: no-repeat;
background-position: center;
background-size: cover;
background-attachment: fixed;
}
.fake1 {
background-image: url(img/bg03.jpg);
background-repeat: no-repeat;
background-position: center;
background-size: cover;
background-attachment: fixed;
}
.bg-custom {
background-color: #ede3ec;
}
.btn-comenzar {
border-radius: 20px;
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
cursor: pointer;
}
.border-card {
2026-07-01 15:28:02 -06:00
background: #e31d73;
background: linear-gradient(to top, #e31d73 0%, #72256b 100%);
2025-10-06 11:13:23 -06:00
}
.btn-answer {
border-radius: 40px;
background-color: #959595;
cursor: pointer;
color: #fff;
font-weight: 700;
}
.btn-answer:hover {
background-color: #72256b;
}
2025-10-06 19:38:34 -06:00
.btn-reintentar {
cursor: pointer;
}
2025-10-06 11:13:23 -06:00
</style>
2026-07-01 15:28:02 -06:00
<div id="inicio" class="page-sco py-2 py-md-0 h-100">
<div class="container h-100">
<div class="row justify-content-center align-items-center h-100">
<div class="col-11">
<div class="row justify-content-center">
2025-10-06 11:13:23 -06:00
<div class="col-12 text-center animate__animated animate__bounceInDown">
<div class="position-relative d-inline-block">
<h2 class="text-primary mb-1 fw-bold">Terapia segura en casa</h2>
2026-07-01 15:28:02 -06:00
<hr class="border border-2 border-verde-oscuro hr-style my-0 mb-3 opacity-100" />
2025-10-06 11:13:23 -06:00
</div>
</div>
<div class="col-12 mb-3 text-center">
<h4 class="fw-bold text-verde-pino">Precalentar la bolsa</h4>
</div>
<div class="col-12">
<div class="row justify-content-center align-items-center">
2025-10-22 09:12:21 -06:00
<div class="col-4 text-center animate__animated animate__zoomIn">
2026-07-01 15:28:02 -06:00
<img src="img/10.0.png" class="img-fluid" />
2025-10-06 11:13:23 -06:00
</div>
<div class="col-6">
<div class="card bg-custom border-0 rounded-3 p-0 bx-shadow">
<div class="p-3 pb-0 position-relative mb-3 w-100 animate__animated animate__flipInX">
2026-07-01 15:28:02 -06:00
<p>
Omitir las medidas de seguridad podría provocarle
<strong>infecciones del sitio de salida o peritonitis.</strong>
</p>
<p class="mb-0">
Si utiliza DPCA y vive en un medio ambiente con temperaturas exteriores menores a 15°C, puede ser
que sienta más comodidad al <strong>precalentar la bolsa </strong>con solución dializante antes de
utilizarla.
</p>
2025-10-06 11:13:23 -06:00
</div>
<div
2026-07-01 15:28:02 -06:00
class="position-relative w-100 bg-lila-rosa text-primary px-3 py-2 mb-3 animate__animated animate__flipInX animate__delay-1s"
>
2025-10-06 11:13:23 -06:00
<p class="mb-0 fw-bold text-center">Conozcamos las medidas de seguridad para hacerlo.</p>
</div>
<div class="position-relative w-100 text-center animate__animated animate__zoomIn animate__delay-2s">
<div
2026-07-01 15:28:02 -06:00
class="btn-comenzar bg-primary d-inline-block px-3 py-2 text-center animate__animated animate__pulse animate__infinite"
>
2025-10-06 11:13:23 -06:00
<h5 class="text-white fw-bold mb-0">COMENZAR ACTIVIDAD</h5>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
2026-07-01 15:28:02 -06:00
<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="row justify-content-center align-items-center h-100">
<div class="col-11">
<div class="row justify-content-center">
2025-10-06 11:13:23 -06:00
<div class="col-10 text-center animate__animated animate__bounceInDown">
<div class="position-relative d-inline-block">
<h2 class="text-primary mb-1 fw-bold">Terapia segura en casa</h2>
2026-07-01 15:28:02 -06:00
<hr class="border border-2 border-verde-oscuro hr-style my-0 mb-2 opacity-100" />
2025-10-06 11:13:23 -06:00
</div>
</div>
<div class="col-10 mb-1 text-center">
<h4 class="fw-bold text-verde-pino">Precalentar la bolsa</h4>
</div>
<div class="col-10 mb-3">
<div class="card bg-lila-rosa border-0 rounded-4 bx-shadow py-2 px-3">
<div class="row justify-content-center">
<div class="col-10">
<div class="d-flex flex-row justify-content-center align-items-center gap-3">
2026-07-01 15:28:02 -06:00
<img src="img/book0.png" class="img-fluid" />
<p class="mb-0">
<strong>Instrucciones:</strong> Lea las siguientes frases y determine si son verdaderas o falsas
para identificar las medidas de seguridad al precalentar la bolsa.
</p>
2025-10-06 11:13:23 -06:00
</div>
</div>
</div>
</div>
</div>
2026-07-01 15:28:02 -06:00
<div class="col-12 mb-3 text-center">
<p class="small mb-0">"Estos son casos hipotéticos basados en las referencias bibliográficas."</p>
</div>
2025-10-06 11:13:23 -06:00
<div class="col-8">
2026-07-01 15:28:02 -06:00
<div
class="card border-card rounded-3 bx-shadow p-1 animate__animated animate__zoomIn"
style="margin-top: 70px"
>
2025-10-06 11:13:23 -06:00
<div class="card-body bg-white border-0 rounded-3 shadow-none px-3 pb-3 pt-0">
<div class="row justify-content-center">
<div class="col-12 text-center mb-3">
2026-07-01 15:28:02 -06:00
<img src="img/10.1.png" class="img-fluid" style="margin-top: -70px" />
2025-10-06 11:13:23 -06:00
</div>
<div class="col-12 txt-pregunta fw-bold text-verde-oscuro text-center mb-3"></div>
<div class="col-12">
<div class="d-flex flex-row justify-content-center align-items-center gap-3 content-answers"></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
2026-07-01 15:28:02 -06:00
<div id="cierre" class="page-sco py-2 py-md-0 h-100" style="display: none">
<div class="container h-100">
<div class="row justify-content-center align-items-center h-100">
<div class="col-12">
2025-10-06 11:13:23 -06:00
<div class="row justify-content-center">
<div class="col-12 text-center mb-3">
2026-07-01 15:28:02 -06:00
<img src="img/cierre_actividad.png" class="img-fluid" />
2025-10-06 11:13:23 -06:00
</div>
<div class="col-12 mb-3 text-center">
<div class="position-relative d-inline-block">
<h2 class="text-primary mb-1 fw-bold">Terapia segura en casa</h2>
2026-07-01 15:28:02 -06:00
<hr class="border border-2 border-verde-oscuro hr-style my-0 opacity-100" />
2025-10-06 11:13:23 -06:00
</div>
</div>
<div class="col-12 mb-3 text-center">
<h4 class="fw-bold text-verde-pino">Precalentar la bolsa</h4>
</div>
<div class="col-12 text-center mb-3">
<h4 class="text-secondary fw-bold">Ha concluido la actividad.</h4>
</div>
2026-07-01 15:28:02 -06:00
<div class="col-12 text-center col-reintentar animate__animated animate__zoomIn" style="display: none">
2025-10-06 11:13:23 -06:00
<div
class="btn-reintentar rounded-3 bg-primary d-inline-block px-3 py-2 text-center animate__animated animate__pulse animate__infinite"
2026-07-01 15:28:02 -06:00
onclick="CourseNav.reload()"
>
2025-10-06 11:13:23 -06:00
<h5 class="text-white fw-bold mb-0">Reintentar</h5>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$(function () {
"use strict";
2026-07-01 15:28:02 -06:00
$(".wrap-course-content").addClass("fake");
2025-10-06 11:13:23 -06:00
let questions;
let currentQuestionIndex = 0;
let currentQuestion;
let correctQuestions = 0;
let maxQuestions = -1;
let currentFichaIndex = 0;
2026-07-01 15:28:02 -06:00
const bad = CourseNav.createSound("audio/feedback-incorrect.mpeg");
const good = CourseNav.createSound("audio/feedback-correct.mpeg");
2025-10-06 11:13:23 -06:00
2026-07-01 15:28:02 -06:00
$(".btn-comenzar").click(function (e) {
2025-10-06 11:13:23 -06:00
e.preventDefault();
CourseNav.soundClick();
2026-07-01 15:28:02 -06:00
$("#inicio").hide();
$("#desarrollo").show();
2025-10-06 11:13:23 -06:00
});
2026-07-01 15:28:02 -06:00
const urlExcelFile = "Actividades_Manual_Vantive.xlsx";
2025-10-06 11:13:23 -06:00
function readExcelFile(url, callback) {
var xhr = new XMLHttpRequest();
2026-07-01 15:28:02 -06:00
xhr.open("GET", url, true);
xhr.responseType = "arraybuffer";
2025-10-06 11:13:23 -06:00
xhr.onload = function (e) {
var arrayBuffer = xhr.response;
var data = new Uint8Array(arrayBuffer);
var workbook = XLSX.read(data, { type: "array" });
var result = {};
2026-07-01 15:28:02 -06:00
workbook.SheetNames.forEach((sheetName) => {
2025-10-06 11:13:23 -06:00
var sheet = workbook.Sheets[sheetName];
result[sheetName] = XLSX.utils.sheet_to_json(sheet);
});
callback(result);
};
xhr.send();
}
function procesarPreguntas(data) {
2026-07-01 15:28:02 -06:00
const preguntas = data.map((fila) => {
2025-10-06 11:13:23 -06:00
const opciones = [];
2026-07-01 15:28:02 -06:00
Object.keys(fila).forEach((key) => {
if (key.startsWith("opcion")) {
2025-10-06 11:13:23 -06:00
opciones.push({
text: fila[key].trim(),
2026-07-01 15:28:02 -06:00
correct: key === "opcion_c",
2025-10-06 11:13:23 -06:00
});
}
});
return {
pregunta: fila.pregunta.trim(),
opciones: opciones,
retroalimentacion_correcta: fila.retroalimentacion_correcta.trim(),
2026-07-01 15:28:02 -06:00
retroalimentacion_incorrecta: fila.retroalimentacion_incorrecta.trim(),
2025-10-06 11:13:23 -06:00
};
});
return preguntas;
}
function shuffleArray(array) {
for (let i = array.length - 1; i > 0; i--) {
const j = Math.floor(Math.random() * (i + 1));
[array[i], array[j]] = [array[j], array[i]];
}
return array;
}
function displayQuestion() {
if (currentQuestionIndex >= questions.length) {
showResults();
return;
}
2026-07-01 15:28:02 -06:00
$(".border-card").hide();
2025-10-06 11:13:23 -06:00
currentQuestion = questions[currentQuestionIndex];
2026-07-01 15:28:02 -06:00
$(".txt-pregunta").text(currentQuestion.pregunta);
2025-10-06 11:13:23 -06:00
setTimeout(() => {
2026-07-01 15:28:02 -06:00
$(".border-card").removeClass("animate__zoomIn").addClass("animate__zoomIn").show();
2025-10-06 11:13:23 -06:00
}, 100);
2026-07-01 15:28:02 -06:00
const answersContainer = $(".content-answers");
2025-10-06 11:13:23 -06:00
answersContainer.empty();
const shuffledOpciones = shuffleArray([...currentQuestion.opciones]);
2026-07-01 15:28:02 -06:00
shuffledOpciones.forEach((opcion) => {
const icon = opcion.text.toLowerCase().includes("verdadero")
? '<i class="fa-solid fa-check me-2"></i>'
: '<i class="fa-solid fa-xmark me-2"></i>';
const btn = $(
`<div class="btn-answer px-3 py-2 d-flex flex-row justify-content-center align-items-center" data-answer="${opcion.correct}">${icon}${opcion.text}</div>`,
);
2025-10-06 11:13:23 -06:00
answersContainer.append(btn);
});
2026-07-01 15:28:02 -06:00
$(".btn-answer").click(function () {
const isCorrect = $(this).data("answer") === true;
2025-10-06 11:13:23 -06:00
2026-07-01 15:28:02 -06:00
$(".btn-answer").off("click").css("pointer-events", "none");
2025-10-06 11:13:23 -06:00
if (isCorrect) {
2026-07-01 15:28:02 -06:00
$(this).addClass("bg-success text-white");
2025-10-06 11:13:23 -06:00
correctQuestions++;
} else {
2026-07-01 15:28:02 -06:00
$(this).addClass("bg-danger text-white");
2025-10-06 11:13:23 -06:00
//$('.btn-answer[data-answer="true"]').addClass('bg-success text-white');
}
CourseNav.audioController.stopAllSoundsAndPlay(isCorrect ? good : bad);
showFeedback(isCorrect);
});
}
function showFeedback(isCorrect) {
Swal.fire({
2026-07-01 15:28:02 -06:00
target: document.getElementById("wrap-course-content"),
imageUrl: isCorrect ? "img/good.png" : "img/bad.png",
2025-10-06 11:13:23 -06:00
showConfirmButton: true,
customClass: {
2026-07-01 15:28:02 -06:00
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",
2025-10-06 11:13:23 -06:00
},
confirmButtonText: "Cerrar",
backdrop: "rgba(65, 60, 60, .95)",
width: "35em",
didClose: () => {
currentQuestionIndex++;
displayQuestion();
2026-07-01 15:28:02 -06:00
},
2025-10-06 11:13:23 -06:00
});
}
function showResults() {
const percentage = (correctQuestions / questions.length) * 100;
const passed = percentage >= 80;
2025-10-06 19:38:34 -06:00
CourseNav.setSlideVisited();
2025-10-06 11:13:23 -06:00
if (passed) {
2026-07-01 15:28:02 -06:00
$("#desarrollo").hide();
$("#cierre").show();
2025-10-06 11:13:23 -06:00
} else {
2026-07-01 15:28:02 -06:00
$(".col-reintentar").show();
$("#desarrollo").hide();
$("#cierre").show();
2025-10-06 11:13:23 -06:00
}
}
readExcelFile(urlExcelFile, function (data) {
const hojaDatos = data["Diapositiva 20"];
const preguntasProcesadas = shuffleArray(procesarPreguntas(hojaDatos));
questions = maxQuestions === -1 ? preguntasProcesadas : preguntasProcesadas.slice(0, maxQuestions);
displayQuestion();
});
});
</script>