Changes to weightwise.scroll.pub

root
root
23 days ago
Initial commit
body.html
Changed around line 1
+
+

WeightWise

+

Your personal weight tracking and dietary recommendation system

+
+
+
+
+

Weight Tracker

+
+
+
+
+
+
+
+
+
+
+
+

Set Your Goals

+
+
+
+
+
+
+
+
+
+
+
+
+

Dietary Recommendations

+
+

Enter your goals to get personalized recommendations.

+
+
+
+
+
+

Your journey to better health starts here.

+
index.scroll
Changed around line 1
+ buildHtml
+ baseUrl https://weightwise.scroll.pub
+ metaTags
+ editButton /edit.html
+ title WeightWise - Track Your Weight & Get Dietary Recommendations
+ style.css
+ body.html
+ script.js
prompt.json
Changed around line 1
+ {
+ "id": "793667ff-ad3e-45b9-ae78-f536a66763f9",
+ "object": "chat.completion",
+ "created": 1735537552,
+ "model": "deepseek-chat",
+ "choices": [
+ {
+ "index": 0,
+ "message": {
+ "role": "assistant",
+ "content": "---domain---\nweightwise.scroll.pub\n---index.scroll---\nbuildHtml\nbaseUrl https://weightwise.scroll.pub\nmetaTags\neditButton /edit.html\ntitle WeightWise - Track Your Weight & Get Dietary Recommendations\nstyle.css\nbody.html\nscript.js\n---body.html---\n
\n

WeightWise

\n

Your personal weight tracking and dietary recommendation system

\n
\n\n
\n
\n

Weight Tracker

\n
\n \n \n \n
\n
\n \n
\n
\n\n
\n

Set Your Goals

\n
\n \n \n \n \n \n \n \n
\n
\n\n
\n

Dietary Recommendations

\n
\n

Enter your goals to get personalized recommendations.

\n
\n
\n
\n\n
\n

Your journey to better health starts here.

\n
\n---style.css---\n:root {\n --primary-color: #4CAF50;\n --secondary-color: #45a049;\n --background-color: #f5f5f5;\n --text-color: #333;\n --chart-color: #4CAF50;\n}\n\nbody {\n font-family: 'Segoe UI', system-ui, sans-serif;\n margin: 0;\n padding: 0;\n background-color: var(--background-color);\n color: var(--text-color);\n line-height: 1.6;\n}\n\nheader {\n background: var(--primary-color);\n color: white;\n padding: 2rem;\n text-align: center;\n}\n\nh1 {\n margin: 0;\n font-size: 2.5rem;\n}\n\nmain {\n max-width: 1200px;\n margin: 2rem auto;\n padding: 0 1rem;\n}\n\nsection {\n background: white;\n border-radius: 8px;\n box-shadow: 0 2px 4px rgba(0,0,0,0.1);\n margin-bottom: 2rem;\n padding: 2rem;\n}\n\nform {\n display: grid;\n gap: 1rem;\n margin-bottom: 1.5rem;\n}\n\nlabel {\n font-weight: 600;\n}\n\ninput {\n padding: 0.8rem;\n border: 1px solid #ddd;\n border-radius: 4px;\n font-size: 1rem;\n}\n\nbutton {\n background: var(--primary-color);\n color: white;\n padding: 0.8rem 1.5rem;\n border: none;\n border-radius: 4px;\n cursor: pointer;\n font-size: 1rem;\n transition: background 0.3s ease;\n}\n\nbutton:hover {\n background: var(--secondary-color);\n}\n\n.chart-container {\n position: relative;\n height: 300px;\n margin-top: 2rem;\n}\n\nfooter {\n text-align: center;\n padding: 1rem;\n background: var(--primary-color);\n color: white;\n margin-top: 2rem;\n}\n\n@media (max-width: 768px) {\n h1 {\n font-size: 2rem;\n }\n \n section {\n padding: 1rem;\n }\n \n .chart-container {\n height: 200px;\n }\n}\n---script.js---\n// Initialize weight data\nlet weightData = [];\nlet goals = {\n targetWeight: null,\n timeFrame: null\n};\n\n// Chart setup\nconst ctx = document.getElementById('weightChart').getContext('2d');\nconst chart = new Chart(ctx, {\n type: 'line',\n data: {\n labels: [],\n datasets: [{\n label: 'Weight (kg)',\n data: [],\n borderColor: '#4CAF50',\n fill: false\n }]\n },\n options: {\n responsive: true,\n maintainAspectRatio: false,\n scales: {\n y: {\n beginAtZero: false\n }\n }\n }\n});\n\n// Form submission handlers\ndocument.getElementById('weightForm').addEventListener('submit', function(e) {\n e.preventDefault();\n const weight = parseFloat(document.getElementById('weightInput').value);\n const date = new Date().toLocaleDateString();\n \n weightData.push({ date, weight });\n updateChart();\n updateRecommendations();\n this.reset();\n});\n\ndocument.getElementById('goalForm').addEventListener('submit', function(e) {\n e.preventDefault();\n goals.targetWeight = parseFloat(document.getElementById('targetWeight').value);\n goals.timeFrame = parseInt(document.getElementById('timeFrame').value);\n updateRecommendations();\n this.reset();\n});\n\n// Update chart with new data\nfunction updateChart() {\n const labels = weightData.map(entry => entry.date);\n const data = weightData.map(entry => entry.weight);\n \n chart.data.labels = labels;\n chart.data.datasets[0].data = data;\n chart.update();\n}\n\n// Generate recommendations\nfunction updateRecommendations() {\n const recContent = document.getElementById('recommendationContent');\n \n if (!weightData.length || !goals.targetWeight) {\n recContent.innerHTML = '

Enter your goals to get personalized recommendations.

';\n return;\n }\n\n const currentWeight = weightData[weightData.length - 1].weight;\n const weightDifference = currentWeight - goals.targetWeight;\n const weeklyGoal = weightDifference / goals.timeFrame;\n\n let recommendation = `

Current Weight: ${currentWeight} kg

\n

Target Weight: ${goals.targetWeight} kg

\n

Weekly Goal: ${Math.abs(weeklyGoal.toFixed(1))} kg ${weeklyGoal > 0 ? 'loss' : 'gain'}

`;\n\n if (weeklyGoal > 0) {\n recommendation += `

Weight Loss Tips:

\n
    \n
  • Create a calorie deficit of ${Math.round(weeklyGoal * 7700 / 7)} calories per day
  • \n
  • Increase physical activity
  • \n
  • Focus on whole, unprocessed foods
  • \n
  • Stay hydrated
  • \n
`;\n } else {\n recommendation += `

Weight Gain Tips:

\n
    \n
  • Create a calorie surplus of ${Math.round(Math.abs(weeklyGoal) * 7700 / 7)} calories per day
  • \n
  • Focus on calorie-dense foods
  • \n
  • Incorporate strength training
  • \n
  • Eat frequent, balanced meals
  • \n
`;\n }\n\n recContent.innerHTML = recommendation;\n}\n---end---"
+ },
+ "logprobs": null,
+ "finish_reason": "stop"
+ }
+ ],
+ "usage": {
+ "prompt_tokens": 251,
+ "completion_tokens": 1642,
+ "total_tokens": 1893,
+ "prompt_cache_hit_tokens": 0,
+ "prompt_cache_miss_tokens": 251
+ },
+ "system_fingerprint": "fp_f1afce2943"
+ }
readme.scroll
Changed around line 1
+ # weightwise.scroll.pub
+ Website generated by DeepSeek from prompt: I want a website to track my weight changes and provide dietary recommendations based on my goals
script.js
Changed around line 1
+ // Initialize weight data
+ let weightData = [];
+ let goals = {
+ targetWeight: null,
+ timeFrame: null
+ };
+
+ // Chart setup
+ const ctx = document.getElementById('weightChart').getContext('2d');
+ const chart = new Chart(ctx, {
+ type: 'line',
+ data: {
+ labels: [],
+ datasets: [{
+ label: 'Weight (kg)',
+ data: [],
+ borderColor: '#4CAF50',
+ fill: false
+ }]
+ },
+ options: {
+ responsive: true,
+ maintainAspectRatio: false,
+ scales: {
+ y: {
+ beginAtZero: false
+ }
+ }
+ }
+ });
+
+ // Form submission handlers
+ document.getElementById('weightForm').addEventListener('submit', function(e) {
+ e.preventDefault();
+ const weight = parseFloat(document.getElementById('weightInput').value);
+ const date = new Date().toLocaleDateString();
+
+ weightData.push({ date, weight });
+ updateChart();
+ updateRecommendations();
+ this.reset();
+ });
+
+ document.getElementById('goalForm').addEventListener('submit', function(e) {
+ e.preventDefault();
+ goals.targetWeight = parseFloat(document.getElementById('targetWeight').value);
+ goals.timeFrame = parseInt(document.getElementById('timeFrame').value);
+ updateRecommendations();
+ this.reset();
+ });
+
+ // Update chart with new data
+ function updateChart() {
+ const labels = weightData.map(entry => entry.date);
+ const data = weightData.map(entry => entry.weight);
+
+ chart.data.labels = labels;
+ chart.data.datasets[0].data = data;
+ chart.update();
+ }
+
+ // Generate recommendations
+ function updateRecommendations() {
+ const recContent = document.getElementById('recommendationContent');
+
+ if (!weightData.length || !goals.targetWeight) {
+ recContent.innerHTML = '

Enter your goals to get personalized recommendations.

';
+ return;
+ }
+
+ const currentWeight = weightData[weightData.length - 1].weight;
+ const weightDifference = currentWeight - goals.targetWeight;
+ const weeklyGoal = weightDifference / goals.timeFrame;
+
+ let recommendation = `

Current Weight: ${currentWeight} kg

+

Target Weight: ${goals.targetWeight} kg

+

Weekly Goal: ${Math.abs(weeklyGoal.toFixed(1))} kg ${weeklyGoal > 0 ? 'loss' : 'gain'}

`;
+
+ if (weeklyGoal > 0) {
+ recommendation += `

Weight Loss Tips:

+
    +
  • Create a calorie deficit of ${Math.round(weeklyGoal * 7700 / 7)} calories per day
  • +
  • Increase physical activity
  • +
  • Focus on whole, unprocessed foods
  • +
  • Stay hydrated
  • + `;
    + } else {
    + recommendation += `

    Weight Gain Tips:

    +
      +
    • Create a calorie surplus of ${Math.round(Math.abs(weeklyGoal) * 7700 / 7)} calories per day
    • +
    • Focus on calorie-dense foods
    • +
    • Incorporate strength training
    • +
    • Eat frequent, balanced meals
    • + `;
      + }
      +
      + recContent.innerHTML = recommendation;
      + }
      style.css
      Changed around line 1
      + :root {
      + --primary-color: #4CAF50;
      + --secondary-color: #45a049;
      + --background-color: #f5f5f5;
      + --text-color: #333;
      + --chart-color: #4CAF50;
      + }
      +
      + body {
      + font-family: 'Segoe UI', system-ui, sans-serif;
      + margin: 0;
      + padding: 0;
      + background-color: var(--background-color);
      + color: var(--text-color);
      + line-height: 1.6;
      + }
      +
      + header {
      + background: var(--primary-color);
      + color: white;
      + padding: 2rem;
      + text-align: center;
      + }
      +
      + h1 {
      + margin: 0;
      + font-size: 2.5rem;
      + }
      +
      + main {
      + max-width: 1200px;
      + margin: 2rem auto;
      + padding: 0 1rem;
      + }
      +
      + section {
      + background: white;
      + border-radius: 8px;
      + box-shadow: 0 2px 4px rgba(0,0,0,0.1);
      + margin-bottom: 2rem;
      + padding: 2rem;
      + }
      +
      + form {
      + display: grid;
      + gap: 1rem;
      + margin-bottom: 1.5rem;
      + }
      +
      + label {
      + font-weight: 600;
      + }
      +
      + input {
      + padding: 0.8rem;
      + border: 1px solid #ddd;
      + border-radius: 4px;
      + font-size: 1rem;
      + }
      +
      + button {
      + background: var(--primary-color);
      + color: white;
      + padding: 0.8rem 1.5rem;
      + border: none;
      + border-radius: 4px;
      + cursor: pointer;
      + font-size: 1rem;
      + transition: background 0.3s ease;
      + }
      +
      + button:hover {
      + background: var(--secondary-color);
      + }
      +
      + .chart-container {
      + position: relative;
      + height: 300px;
      + margin-top: 2rem;
      + }
      +
      + footer {
      + text-align: center;
      + padding: 1rem;
      + background: var(--primary-color);
      + color: white;
      + margin-top: 2rem;
      + }
      +
      + @media (max-width: 768px) {
      + h1 {
      + font-size: 2rem;
      + }
      +
      + section {
      + padding: 1rem;
      + }
      +
      + .chart-container {
      + height: 200px;
      + }
      + }