From 3b2448a360e36500df1b39da997bdc5cca2d2aa4 Mon Sep 17 00:00:00 2001 From: Kavalar Date: Fri, 18 Sep 2026 11:59:56 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=20=D0=BB=D0=BE=D0=B0=D0=B4=D0=B5=D1=80=20=D0=BE=D0=B1?= =?UTF-8?q?=D1=80=D0=B0=D0=B1=D0=BE=D1=82=D0=BA=D0=B8=20=D0=BF=D0=BE=D1=81?= =?UTF-8?q?=D0=BB=D0=B5=20=D1=81=D0=BA=D0=B0=D0=BD=D0=B8=D1=80=D0=BE=D0=B2?= =?UTF-8?q?=D0=B0=D0=BD=D0=B8=D1=8F=20(=D1=81=D0=BF=D0=B8=D0=BD=D0=BD?= =?UTF-8?q?=D0=B5=D1=80=20+=20'=D0=9E=D0=B1=D1=80=D0=B0=D0=B1=D0=BE=D1=82?= =?UTF-8?q?=D0=BA=D0=B0=20=D0=B2=D0=B8=D0=B4=D0=B5=D0=BE...')?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/css/med-diag.css | 39 ++++++++++++++++++++++++++++++++++++++- assets/js/med-diag.js | 5 +++++ med-diagnostics.php | 9 +++++++++ 3 files changed, 52 insertions(+), 1 deletion(-) diff --git a/assets/css/med-diag.css b/assets/css/med-diag.css index 7d88883..86b4068 100644 --- a/assets/css/med-diag.css +++ b/assets/css/med-diag.css @@ -369,4 +369,41 @@ .med-metrics-table td:first-child { font-weight: 600; color: #555; } .med-summary-box, .med-warnings-box, .med-advice-box { padding: 12px 14px; font-size: 15px; } .med-progress-text { font-size: 13px; } -} \ No newline at end of file +} + +/* Лоадер обработки (после сканирования) */ +.med-scan-loader { + display: none; + position: fixed; + inset: 0; + z-index: 1000; + background: rgba(0, 0, 0, 0.7); + align-items: center; + justify-content: center; +} +.med-scan-loader.open { + display: flex; +} +.med-scan-loader-content { + text-align: center; + color: #fff; +} +.med-scan-loader-spinner { + width: 48px; + height: 48px; + border: 4px solid rgba(255,255,255,0.3); + border-top-color: #fff; + border-radius: 50%; + animation: med-spin 0.8s linear infinite; + margin: 0 auto 20px; +} +.med-scan-loader-text { + font-size: 20px; + font-weight: 600; + margin-bottom: 8px; +} +.med-scan-loader-sub { + font-size: 14px; + opacity: 0.8; +} +@keyframes med-spin { to { transform: rotate(360deg); } } \ No newline at end of file diff --git a/assets/js/med-diag.js b/assets/js/med-diag.js index 8917884..c9ff8dc 100644 --- a/assets/js/med-diag.js +++ b/assets/js/med-diag.js @@ -123,6 +123,7 @@ } setProgress(100, 'Готово!'); + document.getElementById('scanLoader').classList.remove('open'); setTimeout(function () { progressContainer.style.display = 'none'; renderResult(data); @@ -151,6 +152,7 @@ } function showError(msg, videoUrl) { + document.getElementById('scanLoader').classList.remove('open'); progressContainer.style.display = 'none'; resultCard.style.display = 'block'; var html = '
Ошибка: ' + escapeHtml(msg) + '
'; @@ -164,6 +166,7 @@ } function renderResult(data) { + document.getElementById('scanLoader').classList.remove('open'); resultCard.style.display = 'block'; var html = ''; @@ -329,6 +332,8 @@ stopCamera(); scanActive = false; scanBtn.disabled = false; + // Показываем лоадер обработки + document.getElementById('scanLoader').classList.add('open'); sendVideo(blob, 'scan.' + ext); }; mediaRecorder.start(); diff --git a/med-diagnostics.php b/med-diagnostics.php index 4411325..4886622 100644 --- a/med-diagnostics.php +++ b/med-diagnostics.php @@ -309,6 +309,15 @@ function med_diag_shortcode( $atts ) {
Поместите лицо в овал целиком: лоб, глаза и подбородок — с запасом. Если голова не помещается — отодвиньте телефон
+ + +
+
+
+
Обработка видео...
+
Идёт анализ, это займёт несколько секунд
+
+