From 053a96b733f1c7ab188045be66b09dafb9b26a5e Mon Sep 17 00:00:00 2001 From: marwin Date: Sun, 20 Apr 2025 17:09:30 +0100 Subject: [PATCH] start --- website/app.py | 17 ++++++++++++ website/static/background.mp4 | 1 + website/static/mindmap.js | 49 ++++++++++++++++++++++++++++++++++ website/static/style.css | 27 +++++++++++++++++++ website/static/three.min.js | 0 website/templates/index.html | 18 +++++++++++++ website/templates/mindmap.html | 14 ++++++++++ 7 files changed, 126 insertions(+) create mode 100644 website/app.py create mode 100644 website/static/background.mp4 create mode 100644 website/static/mindmap.js create mode 100644 website/static/style.css create mode 100644 website/static/three.min.js create mode 100644 website/templates/index.html create mode 100644 website/templates/mindmap.html diff --git a/website/app.py b/website/app.py new file mode 100644 index 0000000..80127d2 --- /dev/null +++ b/website/app.py @@ -0,0 +1,17 @@ +from flask import Flask, render_template + +app = Flask(__name__) + +# Route für die Startseite +@app.route('/') +def index(): + return render_template('index.html') + +# Route für die Mindmap-Seite +@app.route('/mindmap') +def mindmap(): + return render_template('mindmap.html') + +# Flask starten +if __name__ == '__main__': + app.run(debug=True) \ No newline at end of file diff --git a/website/static/background.mp4 b/website/static/background.mp4 new file mode 100644 index 0000000..050b743 --- /dev/null +++ b/website/static/background.mp4 @@ -0,0 +1 @@ +C:\Users\firem\Downloads\background.mp4 diff --git a/website/static/mindmap.js b/website/static/mindmap.js new file mode 100644 index 0000000..15d2732 --- /dev/null +++ b/website/static/mindmap.js @@ -0,0 +1,49 @@ +// Erstelle eine einfache Mindmap-Struktur mit D3.js +const data = { + name: "Wissenschaftliche Mindmap", + children: [ + { name: "Forschung", children: [{ name: "Theorie" }, { name: "Experimente" }] }, + { name: "Technologie", children: [{ name: "Datenbanken" }, { name: "Cloud Computing" }] } + ] +}; + +// D3.js-Setup für die Darstellung der Mindmap +const width = 800; +const height = 600; +const margin = 50; + +const svg = d3.select("#mindmap") + .append("svg") + .attr("width", width) + .attr("height", height); + +const root = d3.hierarchy(data); +const treeLayout = d3.tree().size([width - margin, height - margin]); +treeLayout(root); + +const links = svg.selectAll(".link") + .data(root.links()) + .enter() + .append("line") + .attr("class", "link") + .attr("x1", d => d.source.x + margin) + .attr("y1", d => d.source.y + margin) + .attr("x2", d => d.target.x + margin) + .attr("y2", d => d.target.y + margin) + .attr("stroke", "#2c3e50"); + +const nodes = svg.selectAll(".node") + .data(root.descendants()) + .enter() + .append("g") + .attr("class", "node") + .attr("transform", d => `translate(${d.x + margin},${d.y + margin})`); + +nodes.append("circle") + .attr("r", 20) + .attr("fill", "#3498db"); + +nodes.append("text") + .attr("dx", 25) + .attr("dy", 5) + .text(d => d.data.name); \ No newline at end of file diff --git a/website/static/style.css b/website/static/style.css new file mode 100644 index 0000000..6dc98ff --- /dev/null +++ b/website/static/style.css @@ -0,0 +1,27 @@ +/* Grundlegendes Styling für die Seite */ +body { + font-family: Arial, sans-serif; + margin: 0; + padding: 0; + background-color: #f0f0f0; +} + +/* Styling für den Header */ +h1 { + text-align: center; + color: #2c3e50; + margin-top: 50px; +} + +/* Button für die Navigation */ +button { + padding: 10px 20px; + background-color: #3498db; + color: white; + border: none; + cursor: pointer; +} + +button:hover { + background-color: #2980b9; +} \ No newline at end of file diff --git a/website/static/three.min.js b/website/static/three.min.js new file mode 100644 index 0000000..e69de29 diff --git a/website/templates/index.html b/website/templates/index.html new file mode 100644 index 0000000..66b2c56 --- /dev/null +++ b/website/templates/index.html @@ -0,0 +1,18 @@ + + + + + Wissenschaftliche Mindmap + + + + +
+

Willkommen zur Wissenschafts-Mindmap

+

Verknüpfe Wissen in neuronalen Strukturen.

+ Starte die Mindmap +
+ + \ No newline at end of file diff --git a/website/templates/mindmap.html b/website/templates/mindmap.html new file mode 100644 index 0000000..5d6438d --- /dev/null +++ b/website/templates/mindmap.html @@ -0,0 +1,14 @@ + + + + + Wissenschaftliche Mindmap + + + + +

Wissenschaftliche Mindmap

+
+ + + \ No newline at end of file