feat: playwright scraper

This commit is contained in:
ISA
2025-08-18 14:16:44 +02:00
parent e6aafd6b0c
commit 8097246049
9 changed files with 7804 additions and 5 deletions

View File

@@ -6,6 +6,6 @@ NEXT_PUBLIC_USE_MOCK_BACKEND_LOOP_START=false
NEXT_PUBLIC_EXPORT_STATIC=false
NEXT_PUBLIC_USE_CGI=false
# App-Versionsnummer
NEXT_PUBLIC_APP_VERSION=1.6.735
NEXT_PUBLIC_APP_VERSION=1.6.736
NEXT_PUBLIC_CPL_MODE=json # json (Entwicklungsumgebung) oder jsSimulatedProd (CPL ->CGI-Interface-Simulator) oder production (CPL-> CGI-Interface Platzhalter)

View File

@@ -5,5 +5,5 @@ NEXT_PUBLIC_CPL_API_PATH=/CPL
NEXT_PUBLIC_EXPORT_STATIC=true
NEXT_PUBLIC_USE_CGI=true
# App-Versionsnummer
NEXT_PUBLIC_APP_VERSION=1.6.735
NEXT_PUBLIC_APP_VERSION=1.6.736
NEXT_PUBLIC_CPL_MODE=production

View File

@@ -1,3 +1,8 @@
## [1.6.736] 2025-08-18
- fix: window.location.pathname statt gestes Wert
---
## [1.6.735] 2025-08-18
- fix: Kabelüberwachung Konfiguration sichern und zurücksetzen

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "cpl-v4",
"version": "1.6.735",
"version": "1.6.736",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "cpl-v4",
"version": "1.6.735",
"version": "1.6.736",
"dependencies": {
"@fontsource/roboto": "^5.1.0",
"@headlessui/react": "^2.2.4",

View File

@@ -1,6 +1,6 @@
{
"name": "cpl-v4",
"version": "1.6.735",
"version": "1.6.736",
"private": true,
"scripts": {
"dev": "next dev",

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 285 KiB

View File

@@ -0,0 +1,25 @@
// playwright/scraper/scrape-dashboard.js
import { chromium, devices } from "playwright";
import { writeFileSync } from "fs";
const browser = await chromium.launch();
const context = await browser.newContext({
...devices["iPad Pro 11 landscape"],
});
const page = await context.newPage();
await page.goto("http://localhost:3000/dashboard", {
waitUntil: "networkidle",
});
// HTML speichern
const html = await page.content();
writeFileSync("playwright/scraper/pages/dashboard-ipadpro.html", html);
// Screenshot speichern
await page.screenshot({
path: "playwright/scraper/pages/dashboard-ipadpro.png",
fullPage: true,
});
await browser.close();
// node playwright/scraper/scrape-dashboard.js

View File

@@ -1,5 +1,6 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
darkMode: 'class',
content: [
"./pages/**/*.{js,ts,jsx,tsx,mdx}",
"./components/**/*.{js,ts,jsx,tsx,mdx}",
@@ -20,6 +21,7 @@ module.exports = {
lg: "1024px",
xl: "1280px",
laptop: "1350px",
"ipad-pro": "1024px",
"2xl": "1600px",
"3xl": "1920px",
qhd: "2560px",