Installer workflow is done - Docker container is working fine
This commit is contained in:
@@ -12,14 +12,11 @@
|
||||
<link href="<c:url value='/css/matrix-v2.css' />" rel="stylesheet" />
|
||||
<link href="<c:url value='/css/login-v2.css?v=4' />" rel="stylesheet" />
|
||||
<script src="<c:url value='/js/bootstrap-5.3.8.bundle.min.js' />" defer></script>
|
||||
<script src="<c:url value='/js/login-v2.js?v=3' />" defer></script>
|
||||
<title>Cygnus 1.0 | Login</title>
|
||||
<script src="/matrix/js/matrix-accessibility-v1.js?v=1" defer></script>
|
||||
<link href="/matrix/css/matrix-theme-v2.css?v=4" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body class="matrix-v2 matrix-login"
|
||||
data-context-path="${pageContext.request.contextPath}"
|
||||
data-birthday-url="<c:url value='/ver/fetchdob' />">
|
||||
<body class="matrix-v2 matrix-login">
|
||||
<header class="matrix-login__brand" aria-label="Cygnus application">
|
||||
<div class="matrix-login__brand-inner">
|
||||
<span class="matrix-login__product"><img src="<c:url value='/images/optmale.png' />" width="16" height="16" alt="" /> Cygnus 1.0</span>
|
||||
@@ -28,9 +25,6 @@
|
||||
</header>
|
||||
|
||||
<main class="matrix-login__main">
|
||||
<section id="birthdayBanner" class="matrix-login__birthday"
|
||||
aria-live="polite" aria-label="Birthday announcements" hidden></section>
|
||||
|
||||
<section class="card matrix-login__card shadow-sm" aria-labelledby="loginTitle">
|
||||
<div class="matrix-login__card-heading">
|
||||
<div>
|
||||
|
||||
@@ -121,34 +121,6 @@ body.matrix-login {
|
||||
min-height: 34px;
|
||||
}
|
||||
|
||||
.matrix-login__birthday {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
gap: var(--matrix-space-3);
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.matrix-login__birthday[hidden] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.matrix-login__birthday-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--matrix-space-2);
|
||||
color: var(--matrix-color-danger);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.matrix-login__birthday-item img {
|
||||
width: 72px;
|
||||
height: 72px;
|
||||
object-fit: cover;
|
||||
border: 1px solid var(--matrix-color-border);
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.matrix-login__main > .alert {
|
||||
width: 100%;
|
||||
font-size: 12px;
|
||||
|
||||
@@ -1,57 +0,0 @@
|
||||
(() => {
|
||||
"use strict";
|
||||
|
||||
const closeButton = document.getElementById("closeLogin");
|
||||
const birthdayBanner = document.getElementById("birthdayBanner");
|
||||
const birthdayUrl = document.body.dataset.birthdayUrl;
|
||||
|
||||
closeButton?.addEventListener("click", () => window.close());
|
||||
|
||||
if (!birthdayBanner || !birthdayUrl) {
|
||||
return;
|
||||
}
|
||||
|
||||
const showBirthdayAnnouncements = (responseText) => {
|
||||
const fragment = document.createDocumentFragment();
|
||||
|
||||
responseText.split("!R0W!").filter(Boolean).forEach((row) => {
|
||||
const [message, imageName] = row.split("!C0L!");
|
||||
if (!message || !imageName || !/^[a-zA-Z0-9_-]+$/.test(imageName)) {
|
||||
return;
|
||||
}
|
||||
|
||||
const item = document.createElement("div");
|
||||
item.className = "matrix-login__birthday-item";
|
||||
|
||||
const text = document.createElement("span");
|
||||
text.textContent = `${message}!`;
|
||||
|
||||
const image = document.createElement("img");
|
||||
image.src = `${document.body.dataset.contextPath || ""}/images/dob/${imageName}.jpg`;
|
||||
image.alt = "Birthday announcement";
|
||||
|
||||
item.append(text, image);
|
||||
fragment.append(item);
|
||||
});
|
||||
|
||||
if (fragment.childNodes.length > 0) {
|
||||
birthdayBanner.replaceChildren(fragment);
|
||||
birthdayBanner.hidden = false;
|
||||
}
|
||||
};
|
||||
|
||||
fetch(birthdayUrl, {
|
||||
method: "POST",
|
||||
headers: { "Content-Type": "application/x-www-form-urlencoded;charset=ISO-8859-1" },
|
||||
body: new URLSearchParams({ val0: "1", val1: "5" })
|
||||
})
|
||||
.then((response) => response.ok ? response.text() : Promise.reject(new Error("Request failed")))
|
||||
.then((responseText) => {
|
||||
if (!responseText.includes("Error")) {
|
||||
showBirthdayAnnouncements(responseText);
|
||||
}
|
||||
})
|
||||
.catch(() => {
|
||||
// Birthday announcements are optional and must not block authentication.
|
||||
});
|
||||
})();
|
||||
Reference in New Issue
Block a user