nenn mich designer

This commit is contained in:
2025-05-02 08:51:40 +01:00
parent 4c402423c0
commit 5e97381c8f
3 changed files with 26 additions and 34 deletions

View File

@@ -39,11 +39,10 @@ class NeuralNetworkBackground {
this.connections = [];
this.activeConnections = new Set();
this.animationFrameId = null;
this.isDarkMode = true;
this.isDestroying = false;
// Farben - Lila Farbpalette
this.darkModeColors = {
this.colors = {
background: '#040215',
nodeColor: '#6a5498',
nodePulse: '#9c7fe0',
@@ -51,15 +50,6 @@ class NeuralNetworkBackground {
flowColor: '#b47fea'
};
// Farben für Light Mode mit Lila-Akzenten
this.lightModeColors = {
background: '#f8f6fc',
nodeColor: '#6a5498',
nodePulse: '#9c7fe0',
connectionColor: '#7e70a5',
flowColor: '#a06cd5'
};
// Konfiguration
this.config = {
nodeCount: 80, // Anzahl der Knoten
@@ -78,9 +68,6 @@ class NeuralNetworkBackground {
// Event-Listener
window.addEventListener('resize', this.resizeCanvas.bind(this));
document.addEventListener('darkModeToggled', (event) => {
this.isDarkMode = event.detail.isDark;
});
console.log('Vereinfachter Neural Network Background initialized');
}
@@ -279,7 +266,7 @@ class NeuralNetworkBackground {
}
render(now) {
const colors = this.isDarkMode ? this.darkModeColors : this.lightModeColors;
const colors = this.colors;
const width = this.canvas.width / (window.devicePixelRatio || 1);
const height = this.canvas.height / (window.devicePixelRatio || 1);
@@ -398,4 +385,8 @@ class NeuralNetworkBackground {
// Initialisiert den Hintergrund, sobald die Seite geladen ist
document.addEventListener('DOMContentLoaded', () => {
window.neuralBackground = new NeuralNetworkBackground();
// Sicherstellen, dass die Seite immer im Dark Mode ist
document.documentElement.classList.add('dark');
document.body.classList.add('dark');
});