Changes to type.scroll.pub

root
root
10 days ago
Initial commit
index.scroll
Changed around line 1
+ buildHtml
+ baseUrl https://type.scroll.pub
+ metaTags
+ editButton /edit.html
+ title Touch Typing Master - Improve Your Typing Speed
+ style.css
+ header
+ class hero
+ nav
+ div TouchType
+ class logo
+ div
+ class nav-links
+ a Practice
+ href #practice
+ a Stats
+ href #stats
+ a Guide
+ href #guide
+ main
+ section
+ id practice
+ class typing-test
+ h1 Improve Your Typing Speed
+ p Type the text below:
+ div
+ class text-display
+ id textDisplay
+ div
+ class input-area
+ textarea
+ id userInput
+ placeholder Start typing here...
+ div
+ class stats-display
+ span WPM:
+ id wpm
+ 0
+ span Accuracy:
+ id accuracy
+ 0%
+ span Time:
+ id timer
+ 60s
+ section
+ id stats
+ class statistics
+ h2 Your Progress
+ div
+ class stats-grid
+ div
+ class stat-card
+ h3 Best Speed
+ p
+ id bestWpm
+ 0 WPM
+ div
+ class stat-card
+ h3 Average Accuracy
+ p
+ id avgAccuracy
+ 0%
+ div
+ class stat-card
+ h3 Tests Completed
+ p
+ id testsCompleted
+ 0
+ section
+ id guide
+ class typing-guide
+ h2 Typing Tips
+ div
+ class guide-grid
+ div
+ class guide-card
+ h3 Posture
+ p Sit straight, keep your feet flat on the floor
+ div
+ class guide-card
+ h3 Hand Position
+ p Rest your fingers on the home row keys
+ div
+ class guide-card
+ h3 Focus
+ p Look at the screen, not your hands
+ footer
+ div
+ class footer-content
+ p Made with ❤️ for faster typing
+ div
+ class footer-links
+ a Practice
+ href #practice
+ a Statistics
+ href #stats
+ a Guide
+ href #guide
+ script.js
prompt.json
Changed around line 1
+ {
+ "id": "msg_01NheL57K54R6RdQNgi1rFox",
+ "type": "message",
+ "role": "assistant",
+ "model": "claude-3-5-sonnet-20241022",
+ "content": [
+ {
+ "type": "text",
+ "text": "For a touch typing website, I suggest the domain \"type.scroll.pub\" - it's short, memorable, and clearly represents the purpose of the website.\n\n---domain---\ntype.scroll.pub\n---index.scroll---\nbuildHtml\nbaseUrl https://type.scroll.pub\nmetaTags\neditButton /edit.html\ntitle Touch Typing Master - Improve Your Typing Speed\nstyle.css\nheader\n class hero\n nav\n div TouchType\n class logo\n div\n class nav-links\n a Practice\n href #practice\n a Stats\n href #stats\n a Guide\n href #guide\nmain\n section\n id practice\n class typing-test\n h1 Improve Your Typing Speed\n p Type the text below:\n div\n class text-display\n id textDisplay\n div\n class input-area\n textarea\n id userInput\n placeholder Start typing here...\n div\n class stats-display\n span WPM:\n id wpm\n 0\n span Accuracy:\n id accuracy\n 0%\n span Time:\n id timer\n 60s\n section\n id stats\n class statistics\n h2 Your Progress\n div\n class stats-grid\n div\n class stat-card\n h3 Best Speed\n p\n id bestWpm\n 0 WPM\n div\n class stat-card\n h3 Average Accuracy\n p\n id avgAccuracy\n 0%\n div\n class stat-card\n h3 Tests Completed\n p\n id testsCompleted\n 0\n section\n id guide\n class typing-guide\n h2 Typing Tips\n div\n class guide-grid\n div\n class guide-card\n h3 Posture\n p Sit straight, keep your feet flat on the floor\n div\n class guide-card\n h3 Hand Position\n p Rest your fingers on the home row keys\n div\n class guide-card\n h3 Focus\n p Look at the screen, not your hands\nfooter\n div\n class footer-content\n p Made with ❤️ for faster typing\n div\n class footer-links\n a Practice\n href #practice\n a Statistics\n href #stats\n a Guide\n href #guide\nscript.js\n---style.css---\n:root {\n --primary: #2563eb;\n --secondary: #1e40af;\n --background: #f8fafc;\n --text: #1e293b;\n --accent: #3b82f6;\n}\n\n* {\n margin: 0;\n padding: 0;\n box-sizing: border-box;\n font-family: 'Inter', system-ui, sans-serif;\n}\n\nbody {\n background: var(--background);\n color: var(--text);\n line-height: 1.6;\n}\n\n.hero {\n background: linear-gradient(135deg, var(--primary), var(--secondary));\n padding: 1rem;\n color: white;\n}\n\nnav {\n display: flex;\n justify-content: space-between;\n align-items: center;\n max-width: 1200px;\n margin: 0 auto;\n padding: 1rem;\n}\n\n.logo {\n font-size: 1.5rem;\n font-weight: bold;\n}\n\n.nav-links a {\n color: white;\n text-decoration: none;\n margin-left: 2rem;\n transition: opacity 0.3s;\n}\n\n.nav-links a:hover {\n opacity: 0.8;\n}\n\n.typing-test {\n max-width: 800px;\n margin: 2rem auto;\n padding: 2rem;\n background: white;\n border-radius: 1rem;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);\n}\n\n.text-display {\n font-size: 1.2rem;\n margin: 2rem 0;\n padding: 1rem;\n background: #f1f5f9;\n border-radius: 0.5rem;\n min-height: 100px;\n}\n\n.input-area textarea {\n width: 100%;\n padding: 1rem;\n border: 2px solid #e2e8f0;\n border-radius: 0.5rem;\n font-size: 1.1rem;\n resize: none;\n height: 150px;\n}\n\n.stats-display {\n display: flex;\n gap: 2rem;\n margin-top: 1rem;\n}\n\n.stats-grid, .guide-grid {\n display: grid;\n grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));\n gap: 2rem;\n padding: 2rem;\n max-width: 1200px;\n margin: 0 auto;\n}\n\n.stat-card, .guide-card {\n background: white;\n padding: 2rem;\n border-radius: 1rem;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);\n text-align: center;\n transition: transform 0.3s;\n}\n\n.stat-card:hover, .guide-card:hover {\n transform: translateY(-5px);\n}\n\nfooter {\n background: var(--primary);\n color: white;\n padding: 2rem;\n margin-top: 4rem;\n text-align: center;\n}\n\n.footer-links {\n margin-top: 1rem;\n}\n\n.footer-links a {\n color: white;\n text-decoration: none;\n margin: 0 1rem;\n}\n\n@media (max-width: 768px) {\n .nav-links {\n display: none;\n }\n \n .typing-test {\n margin: 1rem;\n padding: 1rem;\n }\n \n .stats-display {\n flex-direction: column;\n gap: 1rem;\n }\n}\n---script.js---\ndocument.addEventListener('DOMContentLoaded', () => {\n const textDisplay = document.getElementById('textDisplay');\n const userInput = document.getElementById('userInput');\n const wpmDisplay = document.getElementById('wpm');\n const accuracyDisplay = document.getElementById('accuracy');\n const timerDisplay = document.getElementById('timer');\n \n const sampleTexts = [\n \"The quick brown fox jumps over the lazy dog.\",\n \"Pack my box with five dozen liquor jugs.\",\n \"How vexingly quick daft zebras jump!\",\n \"The five boxing wizards jump quickly.\"\n ];\n \n let startTime;\n let timer;\n let isTyping = false;\n \n function initializeTest() {\n textDisplay.textContent = sampleTexts[Math.floor(Math.random() * sampleTexts.length)];\n userInput.value = '';\n wpmDisplay.textContent = '0';\n accuracyDisplay.textContent = '0%';\n timerDisplay.textContent = '60s';\n }\n \n function startTimer() {\n let timeLeft = 60;\n timer = setInterval(() => {\n timeLeft--;\n timerDisplay.textContent = timeLeft + 's';\n if (timeLeft === 0) endTest();\n }, 1000);\n }\n \n function calculateWPM() {\n const words = userInput.value.trim().split(/\\s+/).length;\n const minutes = (Date.now() - startTime) / 60000;\n return Math.round(words / minutes);\n }\n \n function calculateAccuracy() {\n const targetText = textDisplay.textContent;\n const userText = userInput.value;\n let correct = 0;\n \n for (let i = 0; i < userText.length; i++) {\n if (userText[i] === targetText[i]) correct++;\n }\n \n return Math.round((correct / targetText.length) * 100);\n }\n \n function endTest() {\n clearInterval(timer);\n userInput.disabled = true;\n isTyping = false;\n \n // Update stats\n const finalWPM = calculateWPM();\n const finalAccuracy = calculateAccuracy();\n \n if (finalWPM > parseInt(document.getElementById('bestWpm').textContent)) {\n document.getElementById('bestWpm').textContent = finalWPM + ' WPM';\n }\n \n const testsCompleted = parseInt(document.getElementById('testsCompleted').textContent) + 1;\n document.getElementById('testsCompleted').textContent = testsCompleted;\n }\n \n userInput.addEventListener('input', () => {\n if (!isTyping) {\n isTyping = true;\n startTime = Date.now();\n startTimer();\n }\n \n wpmDisplay.textContent = calculateWPM();\n accuracyDisplay.textContent = calculateAccuracy() + '%';\n });\n \n document.addEventListener('keydown', (e) => {\n if (e.code === 'Enter' && !isTyping) {\n initializeTest();\n userInput.disabled = false;\n userInput.focus();\n }\n });\n \n initializeTest();\n});\n---end---\n\nThis implementation creates a professional touch typing practice website with real-time WPM and accuracy tracking, a 60-second timer, and helpful typing tips. The design is clean and modern, with smooth animations and a responsive layout that works well on all devices. The color scheme is professional and easy on the eyes, using a beautiful gradient in the header and subtle shadows for depth."
+ }
+ ],
+ "stop_reason": "end_turn",
+ "stop_sequence": null,
+ "usage": {
+ "input_tokens": 819,
+ "cache_creation_input_tokens": 0,
+ "cache_read_input_tokens": 0,
+ "output_tokens": 2452
+ }
+ }
readme.scroll
Changed around line 1
+ # type.scroll.pub
+
+ Prompt: website
+ Agent: claude
+ Model: claude-3-5-sonnet-20241022
+
+ ## User prompt
+ Touch Typing
+
+ ## System prompt
+ You are an expert web developer. Create a website based on this request: "Touch Typing"
+
+ Requirements:
+ - Use only Scroll, CSS, and JavaScript (NO frameworks, NO external dependencies)
+ - Create clean, semantic HTML5
+ - Make it mobile-responsive
+ - Follow modern best practices and accessibility guidelines
+ - Keep it simple but professional
+ - Use only relative links and no external resources
+ - Do not put a copyright symbol or all rights reserved in the footer.
+ - Make it beautiful. Dazzling. Advanced used of CSS.
+
+ As a refresher, for doing the html body, Scroll is a whitespace based language that uses a single indented space to mark a line (aka particle) as a subparticle of a parent line.
+
+ For example:
+
+ header
+ class hero
+ nav
+ div Scroll
+ class logo
+ div
+ class nav-links
+ a Features
+ href #features
+ a Examples
+ href #examples
+ a Edit
+ href edit.html
+ a GitHub
+ class cta-button
+ href https://github.com/breck7/scroll
+ div
+ class hero-content
+ h1 Write Better with Scroll
+ p The extendible markup language that makes source beautiful and compiles to anything
+ a Get Started
+ class primary-button
+ href https://hub.scroll.pub/
+ main
+ section
+ id features
+ class features
+ h2 Why Scroll?
+ div
+ class feature-grid
+ div
+ class feature-card
+ div ⚡
+ class feature-icon
+ h3 Simple Syntax
+ p Like Markdown, but more powerful. No parentheses needed.
+ div
+ class feature-card
+ div 🧩
+ class feature-icon
+ h3 Extendible
+ p Build your own custom parsers.
+ div
+ class feature-card
+ div 🎨
+ class feature-icon
+ h3 Beautiful Output
+ p Create stunning documents with minimal effort.
+ div
+ class feature-card
+ div 🚀
+ class feature-icon
+ h3 Fast & Light
+ p Built on the efficient PPS Stack.
+ section
+ id examples
+ class code-demo
+ h2 See It In Action
+ div
+ class code-container
+ pre
+ class code-example
+ div
+ class code-output
+ footer
+ div
+ class footer-content
+ div
+ class footer-links
+ a Documentation
+ href https://scroll.pub/tutorial.html
+ a Community
+ href https://www.reddit.com/r/WorldWideScroll/
+ a Blog
+ href https://scroll.pub/blog
+ p Started by Breck Yunits. Evolved by a community.
+ https://twitter.com/breckyunits Breck Yunits
+ https://github.com/breck7/scroll/graphs/contributors community
+
+
+ First suggest a short, memorable domain name ending in scroll.pub that represents this website. Then provide the website files. Use this exact format:
+
+ ---domain---
+ (domainscroll.pub here)
+ ---index.scroll---
+ buildHtml
+ baseUrl https://(domainscroll.pub here)
+ metaTags
+ editButton /edit.html
+ title (Title here)
+ style.css
+
+ (body content here. no blank lines please.)
+
+ script.js
+ ---style.css---
+ (CSS content here)
+ ---script.js---
+ (JavaScript content here)
+ ---end---
script.js
Changed around line 1
+ document.addEventListener('DOMContentLoaded', () => {
+ const textDisplay = document.getElementById('textDisplay');
+ const userInput = document.getElementById('userInput');
+ const wpmDisplay = document.getElementById('wpm');
+ const accuracyDisplay = document.getElementById('accuracy');
+ const timerDisplay = document.getElementById('timer');
+
+ const sampleTexts = [
+ "The quick brown fox jumps over the lazy dog.",
+ "Pack my box with five dozen liquor jugs.",
+ "How vexingly quick daft zebras jump!",
+ "The five boxing wizards jump quickly."
+ ];
+
+ let startTime;
+ let timer;
+ let isTyping = false;
+
+ function initializeTest() {
+ textDisplay.textContent = sampleTexts[Math.floor(Math.random() * sampleTexts.length)];
+ userInput.value = '';
+ wpmDisplay.textContent = '0';
+ accuracyDisplay.textContent = '0%';
+ timerDisplay.textContent = '60s';
+ }
+
+ function startTimer() {
+ let timeLeft = 60;
+ timer = setInterval(() => {
+ timeLeft--;
+ timerDisplay.textContent = timeLeft + 's';
+ if (timeLeft === 0) endTest();
+ }, 1000);
+ }
+
+ function calculateWPM() {
+ const words = userInput.value.trim().split(/\s+/).length;
+ const minutes = (Date.now() - startTime) / 60000;
+ return Math.round(words / minutes);
+ }
+
+ function calculateAccuracy() {
+ const targetText = textDisplay.textContent;
+ const userText = userInput.value;
+ let correct = 0;
+
+ for (let i = 0; i < userText.length; i++) {
+ if (userText[i] === targetText[i]) correct++;
+ }
+
+ return Math.round((correct / targetText.length) * 100);
+ }
+
+ function endTest() {
+ clearInterval(timer);
+ userInput.disabled = true;
+ isTyping = false;
+
+ // Update stats
+ const finalWPM = calculateWPM();
+ const finalAccuracy = calculateAccuracy();
+
+ if (finalWPM > parseInt(document.getElementById('bestWpm').textContent)) {
+ document.getElementById('bestWpm').textContent = finalWPM + ' WPM';
+ }
+
+ const testsCompleted = parseInt(document.getElementById('testsCompleted').textContent) + 1;
+ document.getElementById('testsCompleted').textContent = testsCompleted;
+ }
+
+ userInput.addEventListener('input', () => {
+ if (!isTyping) {
+ isTyping = true;
+ startTime = Date.now();
+ startTimer();
+ }
+
+ wpmDisplay.textContent = calculateWPM();
+ accuracyDisplay.textContent = calculateAccuracy() + '%';
+ });
+
+ document.addEventListener('keydown', (e) => {
+ if (e.code === 'Enter' && !isTyping) {
+ initializeTest();
+ userInput.disabled = false;
+ userInput.focus();
+ }
+ });
+
+ initializeTest();
+ });
style.css
Changed around line 1
+ :root {
+ --primary: #2563eb;
+ --secondary: #1e40af;
+ --background: #f8fafc;
+ --text: #1e293b;
+ --accent: #3b82f6;
+ }
+
+ * {
+ margin: 0;
+ padding: 0;
+ box-sizing: border-box;
+ font-family: 'Inter', system-ui, sans-serif;
+ }
+
+ body {
+ background: var(--background);
+ color: var(--text);
+ line-height: 1.6;
+ }
+
+ .hero {
+ background: linear-gradient(135deg, var(--primary), var(--secondary));
+ padding: 1rem;
+ color: white;
+ }
+
+ nav {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ max-width: 1200px;
+ margin: 0 auto;
+ padding: 1rem;
+ }
+
+ .logo {
+ font-size: 1.5rem;
+ font-weight: bold;
+ }
+
+ .nav-links a {
+ color: white;
+ text-decoration: none;
+ margin-left: 2rem;
+ transition: opacity 0.3s;
+ }
+
+ .nav-links a:hover {
+ opacity: 0.8;
+ }
+
+ .typing-test {
+ max-width: 800px;
+ margin: 2rem auto;
+ padding: 2rem;
+ background: white;
+ border-radius: 1rem;
+ box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
+ }
+
+ .text-display {
+ font-size: 1.2rem;
+ margin: 2rem 0;
+ padding: 1rem;
+ background: #f1f5f9;
+ border-radius: 0.5rem;
+ min-height: 100px;
+ }
+
+ .input-area textarea {
+ width: 100%;
+ padding: 1rem;
+ border: 2px solid #e2e8f0;
+ border-radius: 0.5rem;
+ font-size: 1.1rem;
+ resize: none;
+ height: 150px;
+ }
+
+ .stats-display {
+ display: flex;
+ gap: 2rem;
+ margin-top: 1rem;
+ }
+
+ .stats-grid, .guide-grid {
+ display: grid;
+ grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
+ gap: 2rem;
+ padding: 2rem;
+ max-width: 1200px;
+ margin: 0 auto;
+ }
+
+ .stat-card, .guide-card {
+ background: white;
+ padding: 2rem;
+ border-radius: 1rem;
+ box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
+ text-align: center;
+ transition: transform 0.3s;
+ }
+
+ .stat-card:hover, .guide-card:hover {
+ transform: translateY(-5px);
+ }
+
+ footer {
+ background: var(--primary);
+ color: white;
+ padding: 2rem;
+ margin-top: 4rem;
+ text-align: center;
+ }
+
+ .footer-links {
+ margin-top: 1rem;
+ }
+
+ .footer-links a {
+ color: white;
+ text-decoration: none;
+ margin: 0 1rem;
+ }
+
+ @media (max-width: 768px) {
+ .nav-links {
+ display: none;
+ }
+
+ .typing-test {
+ margin: 1rem;
+ padding: 1rem;
+ }
+
+ .stats-display {
+ flex-direction: column;
+ gap: 1rem;
+ }
+ }