This commit is contained in:
David Martinez 2025-09-23 10:11:35 -06:00
parent 4bc2a47a96
commit b234ae0d22
52 changed files with 733 additions and 64 deletions

BIN
audio/flip.mp3 Normal file

Binary file not shown.

View File

@ -35,6 +35,30 @@
{
"title": "Navegación",
"content": "contenido/08.html"
},
{
"title": "Navegación",
"content": "contenido/09.html"
},
{
"title": "Navegación",
"content": "contenido/10.html"
},
{
"title": "Navegación",
"content": "contenido/11.html"
},
{
"title": "Navegación",
"content": "contenido/12.html"
},
{
"title": "Navegación",
"content": "contenido/13.html"
},
{
"title": "Navegación",
"content": "contenido/14.html"
}
]
}

View File

@ -176,7 +176,7 @@
<script>
$(function () {
'use strict';
$('body').addClass('fake');
$('.wrap-course-content').addClass('fake');
});
// Solución definitiva al error de declaración duplicada

View File

@ -114,7 +114,7 @@
<script>
$(function () {
"use strict";
$('body').addClass('fake');
$('.wrap-course-content').addClass('fake');
let questions;
let currentQuestionIndex = 0;
@ -295,4 +295,4 @@
$(window).on('resize', igualarAlturaBgCustomTransparent);
igualarAlturaBgCustomTransparent();
});
</script>
</script>

View File

@ -26,8 +26,7 @@
.drop-card {
border: none;
width: 200px;
min-width: 80px;
width: 100%;
height: 40px;
}
@ -105,7 +104,7 @@
<div class="bg-secondary text-white fw-bold py-2 px-2">
1
</div>
<div class="option"></div>
<div class="option w-100"></div>
</div>
</div>
</div>
@ -118,7 +117,7 @@
<div class="bg-secondary text-white fw-bold py-2 px-2">
2
</div>
<div class="option"></div>
<div class="option w-100"></div>
</div>
</div>
</div>
@ -131,7 +130,7 @@
<div class="bg-secondary text-white fw-bold py-2 px-2">
3
</div>
<div class="option"></div>
<div class="option w-100"></div>
</div>
</div>
</div>
@ -144,7 +143,7 @@
<div class="bg-secondary text-white fw-bold py-2 px-2">
4
</div>
<div class="option"></div>
<div class="option w-100"></div>
</div>
</div>
</div>
@ -181,7 +180,7 @@
<script>
$(function () {
"use strict";
$('body').addClass('fake');
$('.wrap-course-content').addClass('fake');
let questions;
let currentQuestionIndex = 0;

View File

@ -119,7 +119,7 @@
<script>
$(function () {
'use strict';
$('body').addClass('fake');
$('.wrap-course-content').addClass('fake');
let questions;
let currentQuestionIndex = 0;
let currentQuestion;

View File

@ -65,7 +65,7 @@
<script>
$(function () {
"use strict";
$('body').addClass('fake');
$('.wrap-course-content').addClass('fake');
// Función para mezclar array (algoritmo Fisher-Yates)
function shuffleArray(array) {

View File

@ -212,7 +212,7 @@
<script>
$(function () {
"use strict";
$('body').addClass('fake');
$('.wrap-course-content').addClass('fake');
let questions;
let currentQuestionIndex = 0;

View File

@ -8,19 +8,44 @@
.hr-style {
opacity: 1;
width: 70%;
width: 85%;
}
.custom-grid {
position: relative;
display: grid;
grid-template-columns: repeat(6, 1fr);
grid-template-rows: auto;
gap: 10px;
justify-content: center;
align-items: center;
max-width: 1280px; /* Esto limita el ancho total */
margin: 0 auto;
width: 100%;
}
.card-container {
width: 100%;
aspect-ratio: 1;
cursor: pointer;
}
.card-container.disabled {
filter: grayscale(1);
pointer-events: none;
}
</style>
<div class='page-sco py-2 py-md-4'>
<div class='container'>
<div class='row justify-content-center align-items-center'>
<div class='page-sco py-2 py-md-4 h-100'>
<div class='container h-100'>
<div class='row justify-content-center align-items-center h-100'>
<div class='col-12'>
<div class='row justify-content-center'>
<div class="col-10 mb-2">
<h2 class="text-center fw-bold text-primary">¿Qué necesito para poder realizar la Diálisis Peritoneal Continua Ambulatoria (DPCA)?</h2>
<hr class="border border-3 border-verde-oscuro hr-style mx-auto my-0">
</div>
<div class="col-10 px-0 mb-3">
<div class="col-10 px-0 mb-1">
<div class="card bg-verde-gris border-0 my-2 rounded-4 bg-custom p-3 text-center">
<div class="d-flex justify-content-center align-items-center flex-row">
<img src="img/08.0.png" class="img-fluid mx-3">
@ -28,6 +53,127 @@
</div>
</div>
</div>
<div class="col-12">
<di class="tablero d-flex flex-column justify-content-center align-items-center gap-2">
<div class="row-questions custom-grid" id="row-questions">
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.1.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.2.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.3.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.4.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.5.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.6.png" class="img-fluid">
</div>
</div>
</div>
<div class="row-answer custom-grid" id="row-answer">
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.1c.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.2c.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.3c.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.4c.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.5c.png" class="img-fluid">
</div>
</div>
<div class="card-container">
<div class="front">
<img src="img/08.front.png" class="img-fluid">
</div>
<div class="back">
<img src="img/08.6c.png" class="img-fluid">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="d-none">
<div id="retro-pop">
<div class="container-fluid">
<div class=" w-100 text-center">
<img src="img/3.5.png" class="img-fluid">
</div>
<div class="row justify-content-center">
<div class="col-12 text-center mb-2">
<h3 class="text-secondary-dark fw-bold">¡Bien hecho!</h3>
</div>
<div class="col-12 text-center">
<p class="mb-0">Has concluido la actividad.</p>
</div>
</div>
</div>
@ -36,6 +182,134 @@
<script>
$(function () {
"use strict";
$('body').addClass('fake');
$('.wrap-course-content').addClass('fake');
const flip_sound = CourseNav.createSound('audio/flip.mp3');
const feedbackcorrect = CourseNav.createSound('audio/feedback-correct.mpeg');
const feedbackincorrect = CourseNav.createSound('audio/feedback-incorrect.mpeg');
// Función para asignar pares a cada tarjeta
function assignPairs(fatherId) {
const optionsContainer = document.getElementById(fatherId);
const optionsArray = Array.from(optionsContainer.children);
optionsArray.forEach((option, index) => {
option.setAttribute('data-par', index);
});
}
// Función para mezclar las tarjetas dentro del contenedor especificado
function randomizeOptions(fatherId) {
const optionsContainer = document.getElementById(fatherId);
const optionsArray = Array.from(optionsContainer.children);
const shuffledOptions = optionsArray.sort(() => Math.random() - 0.5);
shuffledOptions.forEach(option => optionsContainer.appendChild(option));
}
// Inicializar el plugin flip y configurar la lógica del memorama con la restricción de fila
function initializeFlip() {
let flippedCards = [];
let lastFlippedRow = ""; // Para rastrear la última fila girada
$(".card-container").flip({
trigger: 'manual' // Control manual del volteo
});
$(".card-container").on("click", function () {
const $card = $(this);
const currentRow = $card.closest(".row-answer").length > 0 ? "row-answer" : "row-questions";
// Limitar el giro a una carta por fila y evitar tres giros
if (flippedCards.length < 2 && (flippedCards.length === 0 || currentRow !== lastFlippedRow)) {
$card.flip(true);
flippedCards.push($card);
lastFlippedRow = currentRow;
flip_sound.play();
// Si hay dos cartas volteadas, verificar coincidencia
if (flippedCards.length === 2) {
const [firstCard, secondCard] = flippedCards;
if (firstCard.data("par") === secondCard.data("par")) {
// Las tarjetas coinciden, dejarlas volteadas y marcar como emparejadas
firstCard.addClass("disabled");
secondCard.addClass("disabled");
// Agregar el efecto de resplandor
gsap.to(firstCard, {
duration: 1,
boxShadow: "0px 0px 20px 10px #fff",
onComplete: function () {
// Quitar el efecto de resplandor después de 2 segundos
gsap.to(firstCard, {
duration: 1,
delay: 1,
boxShadow: "0px 0px 0px 0px #fff"
});
}
});
// Agregar el efecto de resplandor
gsap.to(secondCard, {
duration: 1,
boxShadow: "0px 0px 20px 10px #fff",
onComplete: function () {
// Quitar el efecto de resplandor después de 2 segundos
gsap.to(secondCard, {
duration: 1,
delay: 1,
boxShadow: "0px 0px 0px 0px #fff"
});
}
});
CourseNav.audioController.stopAllSoundsAndPlay(feedbackcorrect);
flippedCards = [];
checkGameCompletion();
} else {
CourseNav.audioController.stopAllSoundsAndPlay(feedbackincorrect);
// Las tarjetas no coinciden, voltearlas de nuevo después de un breve retraso
setTimeout(() => {
firstCard.flip(false);
secondCard.flip(false);
flippedCards = [];
lastFlippedRow = ""; // Reiniciar el rastreo de fila
}, 850);
}
}
}
});
}
// Verificar si todas las tarjetas han sido emparejadas
function checkGameCompletion() {
const totalPairs = $(".card-container").length / 2;
const matchedPairs = $(".card-container.disabled").length / 2;
if (matchedPairs === totalPairs) {
setTimeout(showFeedbackPopup, 250);
}
}
function showFeedbackPopup() {
const html = $("#retro-pop").html();
Swal.fire({
html: html,
target: "body",
customClass: {
popup: 'pop_html_style border border-3 border-primary rounded-4',
confirmButton: 'btn text-white bg-primary amor fw-semibold animate__animated animate__pulse animate__infinite'
},
confirmButtonText: "Cerrar",
showConfirmButton: true,
allowOutsideClick: false,
allowEscapeKey: false,
backdrop: "rgba(65, 60, 60, .95)",
width: "35em",
didClose: () => {
CourseNav.setSlideVisited();
}
});
}
assignPairs('row-answer');
assignPairs('row-questions');
randomizeOptions('row-answer');
randomizeOptions('row-questions');
initializeFlip();
});
</script>

250
contenido/09.html Normal file
View File

@ -0,0 +1,250 @@
<style>
.fake {
background-image: url(img/bg06.jpg);
background-repeat: no-repeat;
background-position: center;
background-size: cover;
}
.hr-style {
opacity: 1;
width: 80%;
}
.bg-custom {
background: #f0f4f2;
}
.tablero {
position: relative;
display: grid;
grid-template-columns: repeat(6, 1fr);
grid-template-rows: repeat(2, 1fr);
gap: 10px;
justify-content: center;
align-items: center;
max-width: 1280px; /* Esto limita el ancho total */
margin: 0 auto;
width: 100%;
}
.card-container2 {
width: 100%;
aspect-ratio: 1;
cursor: pointer;
}
</style>
<div 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-12'>
<div class='row justify-content-center'>
<div class="col-10 mb-2">
<h2 class="text-center fw-bold text-primary">¿Qué necesito para poder realizar la Diálisis Peritoneal Automatizada (DPA)?</h2>
<hr class="border border-3 border-verde-oscuro hr-style mx-auto my-0">
</div>
<div class="col-9 mb-1">
<div class="card border-0 my-2 rounded-15 bg-custom shadow p-3 py-2 text-center">
<div class="d-flex justify-content-center align-items-center flex-row">
<img src="img/3.1.png" class="img-fluid mx-3">
<p class="mb-0"><strong>Instrucciones:</strong> Da clic en los elementos para descubrir cuáles son necesarios para realizar la DPA.</p>
</div>
</div>
</div>
<div class="col-12">
<div class="tablero">
<div class="card-container2" data-correct="0">
<div class="front">
<img src="img/09.0.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.12.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="1">
<div class="front">
<img src="img/09.1.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.13.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="0">
<div class="front">
<img src="img/09.2.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.12.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="0">
<div class="front">
<img src="img/09.3.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.12.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="1">
<div class="front">
<img src="img/09.4.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.13.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="0">
<div class="front">
<img src="img/09.5.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.12.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="0">
<div class="front">
<img src="img/09.6.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.12.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="0">
<div class="front">
<img src="img/09.7.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.12.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="0">
<div class="front">
<img src="img/09.8.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.12.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="1">
<div class="front">
<img src="img/09.9.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.13.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="1">
<div class="front">
<img src="img/09.10.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.13.png" class="img-fluid">
</div>
</div>
<div class="card-container2" data-correct="1">
<div class="front">
<img src="img/09.11.png" class="img-fluid">
</div>
<div class="back">
<img src="img/09.13.png" class="img-fluid">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="d-none">
<div id="pop0">
<div class="container-fluid">
<div class=" w-100 text-center">
<img src="img/09.14.png" class="img-fluid">
</div>
<div class="row justify-content-center">
<div class="col-12 text-center mb-2">
<h3 class="text-secondary-dark fw-bold">¡Recuerda!</h3>
</div>
<div class="col-12 text-center">
<p class="mb-0">Siempre debes lavar tus manos antes de empezar cualquier terapia.</p>
</div>
</div>
</div>
</div>
</div>
<script>
$(function () {
"use strict";
$('.wrap-course-content').addClass('fake');
const flip_sound = CourseNav.createSound('audio/flip.mp3');
const feedbackcorrect = CourseNav.createSound('audio/feedback-correct.mpeg');
const feedbackincorrect = CourseNav.createSound('audio/feedback-incorrect.mpeg');
$(".card-container2").flip({
trigger: 'manual' // Control manual del volteo
});
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;
}
// Shuffle cards
const tablero = document.querySelector('.tablero');
const cards = Array.from(tablero.querySelectorAll('.card-container2'));
const shuffledCards = shuffleArray(cards);
shuffledCards.forEach(card => tablero.appendChild(card));
$(".card-container2").click(function (e) {
e.preventDefault();
const $card = $(this);
if ($card.hasClass('disabled')) return;
flip_sound.play();
$card.flip(true);
if($card.data('correct') == '0') {
CourseNav.audioController.stopAllSoundsAndPlay(feedbackcorrect);
$card.addClass('disabled');
}else{
CourseNav.audioController.stopAllSoundsAndPlay(feedbackincorrect);
setTimeout(() => {
$card.flip(false);
}, 700);
}
// Check if all correct cards are completed
const correctCards = $('.card-container2[data-correct="0"]');
const completedCorrectCards = $('.card-container2[data-correct="0"].disabled');
if (correctCards.length === completedCorrectCards.length) {
checkAllCompleted();
}
});
function checkAllCompleted() {
setTimeout(() => {
const html = $("#pop0").html();
Swal.fire({
html: html,
target: "body",
customClass: {
popup: 'pop_html_style border border-3 border-primary rounded-4',
confirmButton: 'btn text-white bg-primary amor fw-semibold animate__animated animate__pulse animate__infinite'
},
confirmButtonText: "Cerrar",
showConfirmButton: true,
allowOutsideClick: false,
allowEscapeKey: false,
backdrop: "rgba(65, 60, 60, .95)",
width: "35em",
didClose: () => {
CourseNav.setSlideVisited();
$(".card-container2").addClass('disabled');
}
});
}, 250);
}
});
</script>

45
contenido/10.html Normal file
View File

@ -0,0 +1,45 @@
<style>
.fake {
background-image: url(img/bg07.jpg);
background-repeat: no-repeat;
background-position: center;
background-size: cover;
}
.card-style {
border-radius: 20px;
border-top-left-radius: 0;
border-bottom-left-radius: 0;
}
.hr-style {
opacity: 1;
width: 60%;
}
</style>
<div 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-12 ps-0'>
<div class='row justify-content-center align-items-center'>
<div class="col-5 animate__animated animate__lightSpeedInLeft">
<div class="card card-style bg-verde-oscuro ps-5 pr-3 py-3 border-0 text-center">
<h2 class="text-white fw-bold">¿Qué es un catéter?</h2>
<hr class="hr-style border border-3 border-verde-ceniza hr-style mx-auto my-0">
</div>
</div>
<div class="col-7 text-center animate__animated animate__zoomIn">
<img src="img/10.0.png" class="img-fluid">
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$(function () {
"use strict";
$('.wrap-course-content').addClass('fake');
CourseNav.setSlideVisited();
});
</script>

58
contenido/11.html Normal file
View File

@ -0,0 +1,58 @@
<style>
.fake {
background-image: url(img/bg11.jpg);
background-repeat: no-repeat;
background-position: center;
background-size: cover;
}
.hr-style {
opacity: 1;
width: 40%;
}
.bg-custom {
box-shadow: 0 0 10px rgba(0, 0, 0, .5);
}
</style>
<div 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-12'>
<div class='row justify-content-center'>
<div class="col-10 mb-2 animate__animated animate__bounceInDown">
<h2 class="text-center fw-bold text-primary">Características del sitio de salida</h2>
<hr class="border border-3 border-verde-oscuro hr-style mx-auto my-0">
</div>
<div class="col-12 px-0 mb-1 animate__animated animate__lightSpeedInLeft">
<div class="card bg-white border-0 my-2 rounded-0 bg-custom p-3 text-center">
<div class="d-flex justify-content-center align-items-center flex-row gap-2">
<img src="img/3.1.png" class="img-fluid mx-3">
<div class="parrafos text-start">
<p class="mb-2"><strong>Instrucciones:</strong> Observa las imágenes del sitio de salida que se presentan en las
tarjetas.</p>
<p class="mb-0">Si consideras que se encuentra sano, desliza la tarjeta a la <strong class="text-verde-pino">derecha</strong>. Si
crees que no está sano,
desliza la tarjeta a la <strong class="text-verde-pino">izquierda</strong>.</p>
</div>
</div>
</div>
</div>
<div class="col-12">
<div class="row justify-content-center">
<div class="col-12 mb-2">
<div class="d-flex justify-content-center align-items-center gap-2 flex-row"></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
$(function () {
"use strict";
$('.wrap-course-content').addClass('fake');
});
</script>

View File

@ -380,7 +380,7 @@ body > main {
}
#coursenav-main-content {
height: 100%;
height: calc(100% - 85px);
overflow-x: hidden;
}

2
css/style.min.css vendored

File diff suppressed because one or more lines are too long

View File

@ -495,3 +495,7 @@ h6 {
.pop_html_style .swal2-html-container {
padding: 0.5em;
}
/* .wrap-course-content {
transition: transform 0.3s ease, left 0.3s ease, top 0.3s ease;
} */

View File

@ -481,4 +481,8 @@ h6 {
.pop_html_style .swal2-html-container {
padding: 0.5em;
}
}
/* .wrap-course-content {
transition: transform 0.3s ease, left 0.3s ease, top 0.3s ease;
} */

BIN
img/08.1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

BIN
img/08.1c.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.4 KiB

BIN
img/08.2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

BIN
img/08.2c.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

BIN
img/08.3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

BIN
img/08.3c.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
img/08.4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

BIN
img/08.4c.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.3 KiB

BIN
img/08.5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

BIN
img/08.5c.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

BIN
img/08.6.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

BIN
img/08.6c.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
img/08.front.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.1 KiB

BIN
img/09.0.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

BIN
img/09.1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

BIN
img/09.10.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 39 KiB

BIN
img/09.11.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

BIN
img/09.12.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

BIN
img/09.13.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

BIN
img/09.14.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 KiB

BIN
img/09.2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

BIN
img/09.3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

BIN
img/09.4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

BIN
img/09.5.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

BIN
img/09.6.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

BIN
img/09.7.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

BIN
img/09.8.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

BIN
img/09.9.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

BIN
img/10.0.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 268 KiB

BIN
img/bg06.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 120 KiB

BIN
img/bg07.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

BIN
img/bg11.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB

View File

@ -164,6 +164,7 @@
<script src="js/xlsx.full.min.js"></script>
<script src="js/jquery-ui.min.js"></script>
<script src="js/jquery.ui.touch-punch.min.js"></script>
<script src="js/jquery.flip.min.js"></script>
<!-- Configuración del curso -->
<script src="js/config.min.js" defer></script>
<!-- librería principal -->

View File

@ -167,52 +167,37 @@ function animateOnScroll(selector, animationClass, options = {}) {
return observer;
}
/**
* Ajusta el contenido del curso para ocupar el máximo de pantalla.
* @function scaleWrapCourseContent
*/
function scaleWrapCourseContent() {
const content = document.querySelector('.wrap-course-content');
const mainContent = document.querySelector('#coursenav-main-content');
if (!content) return;
const header = document.querySelector('header');
const footer = document.querySelector('footer');
const headerHeight = header ? header.offsetHeight : 0;
const footerHeight = footer ? footer.offsetHeight : 0;
const ww = window.innerWidth;
const wh = window.innerHeight - headerHeight;
const wh = window.innerHeight;
if (ww < 1366) {
const scale = Math.min(ww / 1366, wh / 768);
content.style.transform = `scale(${scale})`;
content.style.transformOrigin = 'top left';
content.style.width = '1366px';
content.style.height = '768px';
content.style.position = 'absolute';
content.style.left = (ww - 1366 * scale) / 2 + 'px';
content.style.top = headerHeight + (wh - 768 * scale) / 2 + 'px';
content.style.overflow = 'hidden';
if (mainContent) {
const availableHeight = 768 - 80;
mainContent.style.height = availableHeight + 'px';
}
// Breakpoint a 1500px
let baseWidth, baseHeight;
if (ww < 1500) {
// Menor a 1500px: usar 1366x768
baseWidth = 1366;
baseHeight = 768;
} else {
content.style.transform = '';
content.style.transformOrigin = '';
content.style.width = '100%';
content.style.height = '100vh';
content.style.position = 'relative';
content.style.left = '';
content.style.top = '';
content.style.overflow = 'hidden';
if (mainContent) {
mainContent.style.height = `calc(100vh - ${headerHeight + footerHeight}px)`;
}
// 1500px o más: usar 1920x1080
baseWidth = 1920;
baseHeight = 1080;
}
// Escala simple
const scale = Math.min(ww / baseWidth, wh / baseHeight);
content.style.transform = `scale(${scale})`;
content.style.transformOrigin = 'top left';
content.style.width = baseWidth + 'px';
content.style.height = baseHeight + 'px';
content.style.position = 'absolute';
content.style.left = (ww - baseWidth * scale) / 2 + 'px';
content.style.top = (wh - baseHeight * scale) / 2 + 'px';
content.style.overflow = 'hidden';
content.style.zIndex = '1';
}
@ -300,10 +285,29 @@ function gotoFirstMenuToolSlide() {
* @event DOMContentLoaded
*/
document.addEventListener('DOMContentLoaded', () => {
// Ajustar contenido al cargar y redimensionar
// Escalado inicial y continuo
scaleWrapCourseContent();
setTimeout(scaleWrapCourseContent, 100);
window.addEventListener('resize', () => setTimeout(scaleWrapCourseContent, 100));
// Escalado en redimensionamiento con debounce
let resizeTimeout;
window.addEventListener('resize', () => {
clearTimeout(resizeTimeout);
resizeTimeout = setTimeout(scaleWrapCourseContent, 50);
});
// Escalado en cambio de orientación (móviles/tablets)
window.addEventListener('orientationchange', () => {
setTimeout(scaleWrapCourseContent, 200);
});
// Escalado cuando cambia la visibilidad (cambio de pestaña)
document.addEventListener('visibilitychange', () => {
if (!document.hidden) {
setTimeout(scaleWrapCourseContent, 100);
}
});
/**
* Evento antes de cambiar de slide.
* @event beforeSlideChange

2
js/config.min.js vendored

File diff suppressed because one or more lines are too long

6
js/jquery.flip.min.js vendored Normal file
View File

@ -0,0 +1,6 @@
/*! flip - v1.0.11 - 2015-07-13
* https://github.com/nnattawat/flip
* Copyright (c) 2015 Nattawat Nonsung; Licensed MIT */
!function(a){var b=function(a){a.data("flipped",!0);var b="rotate"+a.data("axis");a.find(a.data("front")).css({transform:b+(a.data("reverse")?"(-180deg)":"(180deg)"),"z-index":"0"}),a.find(a.data("back")).css({transform:b+"(0deg)","z-index":"1"})},c=function(a){a.data("flipped",!1);var b="rotate"+a.data("axis");a.find(a.data("front")).css({transform:b+"(0deg)","z-index":"1"}),a.find(a.data("back")).css({transform:b+(a.data("reverse")?"(180deg)":"(-180deg)"),"z-index":"0"})},d=function(){var a,b=document.createElement("fakeelement"),c={transition:"transitionend",OTransition:"oTransitionEnd",MozTransition:"transitionend",WebkitTransition:"webkitTransitionEnd"};for(a in c)if(void 0!==b.style[a])return c[a]};a.fn.flip=function(f,g){return"function"==typeof f&&(g=f),this.each(function(){var h=a(this);if(void 0===f||"boolean"!=typeof f&&"string"!=typeof f)if(h.data("initiated"))void 0!==f.axis&&e.call(this,f.axis,g);else{h.data("initiated",!0);var i=a.extend({axis:"y",reverse:!1,trigger:"click",speed:500,forceHeight:!1,forceWidth:!1,autoSize:!0,front:"auto",back:"auto"},f);"auto"==i.front?i.front=h.find(".front").length>0?".front":"div:first-child":"autostrict"==i.front&&(i.front="div:first-child"),"auto"==i.back?i.back=h.find(".back").length>0?".back":"div:first-child + div":"autostrict"==i.back&&(i.back="div:first-child + div"),h.data("reverse",i.reverse),h.data("axis",i.axis),h.data("front",i.front),h.data("back",i.back);var j="rotate"+("x"==i.axis.toLowerCase()?"x":"y"),k=2*h["outer"+("rotatex"==j?"Height":"Width")]();h.find(h.data("back")).css({transform:j+"("+(i.reverse?"180deg":"-180deg")+")"}),h.css({perspective:k,position:"relative"});var l=i.speed/1e3||.5,m=h.find(i.front).add(i.back,h);if(i.forceHeight?m.outerHeight(h.height()):i.autoSize&&m.css({height:"100%"}),i.forceWidth?m.outerWidth(h.width()):i.autoSize&&m.css({width:"100%"}),m.css({"backface-visibility":"hidden","transform-style":"preserve-3d",position:"absolute","z-index":"1"}),h.find(h.data("back")).css({transform:j+"("+(i.reverse?"180deg":"-180deg")+")","z-index":"0"}),setTimeout(function(){m.css({transition:"all "+l+"s ease-out"}),void 0!==g&&g.call(this)},20),"click"==i.trigger.toLowerCase())h.on(a.fn.tap?"tap":"click",function(){h.find(a(event.target).closest('button, a, input[type="submit"]')).length||(h.data("flipped")?c(h):b(h))});else if("hover"==i.trigger.toLowerCase()){var n=function(){h.unbind("mouseleave",o),b(h),setTimeout(function(){h.bind("mouseleave",o),h.is(":hover")||c(h)},i.speed+150)},o=function(){c(h)};h.mouseenter(n),h.mouseleave(o)}}else"toggle"==f&&(f=!h.data("flipped")),f?b(h):c(h),void 0!==g&&a(this).one(d(),function(){g.call(this)})}),this};var e=function(b,c){if(a(this).data("axis")!=b.toLowerCase()){var d=a(this).find(a(this).data("front")).add(a(this).data("back"),a(this)),e=d.css("transition");d.css({transition:"none"}),b=b.toLowerCase(),a(this).data("axis",b);var f="rotate"+b;a(this).data("flipped")?a(this).find(a(this).data("front")).css({transform:f+(a(this).data("reverse")?"(-180deg)":"(180deg)"),"z-index":"0"}):a(this).find(a(this).data("back")).css({transform:f+"("+(a(this).data("reverse")?"180deg":"-180deg")+")","z-index":"0"}),setTimeout(function(){d.css({transition:e}),void 0!==c&&c.call(this)},0)}else void 0!==c&&setTimeout(c.bind(this),0)}}(jQuery);
//# sourceMappingURL=jquery.flip.min.js.map