Compare commits

...

7 Commits

Author SHA1 Message Date
3ad24ef615 chore: bump version to 1.3.16
Some checks failed
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 5s
🚀 Build & Deploy / 🧪 QA (push) Successful in 1m33s
🚀 Build & Deploy / 🏗️ Build (push) Successful in 15m20s
🚀 Build & Deploy / 🚀 Deploy (push) Failing after 1m22s
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
🚀 Build & Deploy / 🔔 Notify (push) Successful in 1s
2026-04-22 09:26:44 +02:00
3018ae5412 fix: ensure 'Stand' is correctly detected and displayed in the main text body
Some checks failed
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 4s
🚀 Build & Deploy / 🧪 QA (push) Successful in 2m15s
🚀 Build & Deploy / 🏗️ Build (push) Failing after 12m23s
🚀 Build & Deploy / 🚀 Deploy (push) Has been skipped
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
🚀 Build & Deploy / 🔔 Notify (push) Successful in 1s
2026-04-22 09:26:30 +02:00
fd3f4c82c5 chore: bump version to 1.3.15
All checks were successful
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 6s
🚀 Build & Deploy / 🧪 QA (push) Successful in 1m38s
🚀 Build & Deploy / 🏗️ Build (push) Successful in 14m3s
🚀 Build & Deploy / 🚀 Deploy (push) Successful in 10s
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Successful in 3m43s
🚀 Build & Deploy / 🔔 Notify (push) Successful in 2s
2026-04-22 08:59:04 +02:00
3906838dc1 fix: repair AVB parser to correctly detect ## headers and strip markdown artifacts
Some checks failed
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 4s
🚀 Build & Deploy / 🧪 QA (push) Successful in 2m8s
🚀 Build & Deploy / 🏗️ Build (push) Failing after 11m43s
🚀 Build & Deploy / 🚀 Deploy (push) Has been skipped
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
🚀 Build & Deploy / 🔔 Notify (push) Successful in 7s
2026-04-22 08:58:36 +02:00
785e36af08 fix: resolve TS2345 in pageerror handler by using unknown and type guard
Some checks failed
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 5s
🚀 Build & Deploy / 🧪 QA (push) Successful in 1m53s
🚀 Build & Deploy / 🏗️ Build (push) Successful in 11m58s
🚀 Build & Deploy / 🚀 Deploy (push) Successful in 11s
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Successful in 3m27s
🚀 Build & Deploy / 🔔 Notify (push) Successful in 2s
Nightly QA / call-qa-workflow (push) Failing after 26s
2026-04-21 19:32:07 +02:00
d4c32476d6 fix: remove unused urlObj to satisfy linter
Some checks failed
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 4s
🚀 Build & Deploy / 🧪 QA (push) Failing after 50s
🚀 Build & Deploy / 🚀 Deploy (push) Has been cancelled
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Has been cancelled
🚀 Build & Deploy / 🔔 Notify (push) Has been cancelled
🚀 Build & Deploy / 🏗️ Build (push) Has been cancelled
2026-04-21 19:26:25 +02:00
9b9d4634dd fix: rename AGB to AVB in navigation and components for consistency
Some checks failed
🚀 Build & Deploy / 🔍 Prepare (push) Successful in 6s
🚀 Build & Deploy / 🧪 QA (push) Failing after 1m5s
🚀 Build & Deploy / 🚀 Deploy (push) Has been cancelled
🚀 Build & Deploy / 🧪 Post-Deploy Verification (push) Has been cancelled
🚀 Build & Deploy / 🔔 Notify (push) Has been cancelled
🚀 Build & Deploy / 🏗️ Build (push) Has been cancelled
2026-04-21 19:21:47 +02:00
6 changed files with 33 additions and 48 deletions

View File

@@ -2,65 +2,46 @@ import { Download } from "lucide-react";
import fs from "fs"; import fs from "fs";
import path from "path"; import path from "path";
export default function AGB() { export default function AVB() {
const filePath = path.join(process.cwd(), "context/avbs.md"); const filePath = path.join(process.cwd(), "context/avbs.md");
const fileContent = fs.readFileSync(filePath, "utf8"); const fileContent = fs.readFileSync(filePath, "utf8");
// Split by double newlines to get major blocks (headers + their first paragraphs, or subsequent paragraphs) // Split by double newlines to get major blocks
const blocks = fileContent const rawBlocks = fileContent
.split(/\n\s*\n/) .split(/\n\s*\n/)
.map((b) => b.trim()) .map((b) => b.trim())
.filter((b) => b !== ""); .filter((b) => b !== "");
const title = blocks[0] || "Liefer- und Zahlungsbedingungen"; // Extract title and stand more robustly
const stand = blocks[1] || "Stand Januar 2026"; const title = rawBlocks.find(b => b.startsWith("# "))?.replace(/^#\s+/, "") || "Allgemeine Verkaufsbedingungen";
const stand = rawBlocks.find(b => b.toLowerCase().startsWith("stand:")) || "Stand: April 2026";
const sections: { title: string; content: string[] }[] = []; const sections: { title: string; content: string[] }[] = [];
let currentSection: { title: string; content: string[] } | null = null; let currentSection: { title: string; content: string[] } | null = null;
// Skip title and stand // Process sections, skipping title and stand blocks
blocks.slice(2).forEach((block) => { rawBlocks.forEach((block) => {
const lines = block if (block.startsWith("# ") || block.toLowerCase().startsWith("stand:")) return;
.split("\n")
.map((l) => l.trim())
.filter((l) => l !== "");
if (lines.length === 0) return;
const firstLine = lines[0]; if (block.startsWith("##")) {
// New section header: e.g. "## 1. Geltungsbereich"
if (/^\d+\./.test(firstLine)) {
// New section
if (currentSection) sections.push(currentSection); if (currentSection) sections.push(currentSection);
currentSection = {
currentSection = { title: firstLine, content: [] }; title: block.replace(/^##\s+/, "").trim(),
content: []
// If there are more lines in this block, they form the first paragraph(s) };
if (lines.length > 1) {
// Join subsequent lines as they might be part of the same paragraph
// In this MD, we'll assume lines in the same block belong together
// unless they are clearly separate paragraphs (but we already split by double newline)
const remainingText = lines.slice(1).join(" ");
if (remainingText) currentSection.content.push(remainingText);
}
} else if (currentSection) { } else if (currentSection) {
// Continuation of current section // Clean up bold markers for better display
const blockText = lines.join(" "); const cleanedBlock = block.replace(/\*\*(.*?)\*\*/g, "$1");
if (blockText) currentSection.content.push(blockText); currentSection.content.push(cleanedBlock);
} }
}); });
if (currentSection) sections.push(currentSection); if (currentSection) sections.push(currentSection);
// The last block is the footer // The very last block might be a footer/schlussbestimmung if it's not in a section
const footer = blocks[blocks.length - 1]; // In our MD, everything is in a section, so we just use the last block of the last section as potential footer if we want,
if (sections.length > 0) { // but the current UI expects a separate 'footer' variable.
const lastSection = sections[sections.length - 1]; const footer = "MB Grid Solutions & Services";
if (lastSection.content.includes(footer) || lastSection.title === footer) {
lastSection.content = lastSection.content.filter((c) => c !== footer);
if (sections[sections.length - 1].title === footer) {
sections.pop();
}
}
}
return ( return (
<div className="bg-slate-50 min-h-screen pt-40 pb-20"> <div className="bg-slate-50 min-h-screen pt-40 pb-20">
@@ -84,6 +65,9 @@ export default function AGB() {
</div> </div>
<div className="space-y-8 text-slate-600 leading-relaxed"> <div className="space-y-8 text-slate-600 leading-relaxed">
<div className="pb-4 border-b border-slate-50">
<p className="text-slate-400 italic">{stand}</p>
</div>
{sections.map((section, index) => ( {sections.map((section, index) => (
<div key={index}> <div key={index}>
<h2 className="text-2xl font-bold text-primary mb-4"> <h2 className="text-2xl font-bold text-primary mb-4">

View File

@@ -246,7 +246,7 @@ const Layout = ({ children }: { children: React.ReactNode }) => {
href="/agb" href="/agb"
className="hover:text-accent transition-colors" className="hover:text-accent transition-colors"
> >
{t("footer.agb")} {t("footer.avb")}
</Link> </Link>
</nav> </nav>
</div> </div>

View File

@@ -81,7 +81,7 @@
"legal": "Rechtliches", "legal": "Rechtliches",
"impressum": "Impressum", "impressum": "Impressum",
"datenschutz": "Datenschutz", "datenschutz": "Datenschutz",
"agb": "AVB", "avb": "AVB",
"rights": "Alle Rechte vorbehalten.", "rights": "Alle Rechte vorbehalten.",
"madeWith": "Entwickelt mit", "madeWith": "Entwickelt mit",
"precision": "Präzision", "precision": "Präzision",

View File

@@ -1,6 +1,6 @@
{ {
"name": "mb-grid-solutions.com", "name": "mb-grid-solutions.com",
"version": "1.3.14", "version": "1.3.16",
"type": "module", "type": "module",
"packageManager": "pnpm@10.18.3", "packageManager": "pnpm@10.18.3",
"scripts": { "scripts": {

View File

@@ -79,10 +79,11 @@ async function main() {
const consoleErrorsList: Array<{ type: string; error: string; page: string }> = []; const consoleErrorsList: Array<{ type: string; error: string; page: string }> = [];
// Listen for unhandled exceptions natively in the page // Listen for unhandled exceptions natively in the page
page.on('pageerror', (err: Error) => { page.on('pageerror', (err: unknown) => {
const errorMessage = err instanceof Error ? err.message : String(err);
consoleErrorsList.push({ consoleErrorsList.push({
type: 'PAGE_ERROR', type: 'PAGE_ERROR',
error: err.message, error: errorMessage,
page: page.url(), page: page.url(),
}); });
hasConsoleErrors = true; hasConsoleErrors = true;

View File

@@ -94,8 +94,8 @@ async function main() {
baseConfig = JSON.parse(fs.readFileSync(baseConfigPath, 'utf8')); baseConfig = JSON.parse(fs.readFileSync(baseConfigPath, 'utf8'));
} }
// Extract domain for cookie // Extract domain for cookie (not currently used)
const urlObj = new URL(targetUrl); // const urlObj = new URL(targetUrl);
// domain is not used, so remove or keep if needed later? Linter says unused. // domain is not used, so remove or keep if needed later? Linter says unused.
// const domain = urlObj.hostname; // const domain = urlObj.hostname;