commit a803548cff485952db9518591f9d5ed4deeeeaba
Author: root <root@hub.scroll.pub> Date: 2024-12-27 06:41:52 +0000 Subject: Initial commit diff --git a/body.html b/body.html new file mode 100644 index 0000000..5441164 --- /dev/null +++ b/body.html @@ -0,0 +1,71 @@ +<header> + <nav> + <div class="logo">SudokuTips</div> + <div class="menu-toggle" aria-label="Toggle menu"> + <span></span><span></span><span></span> + </div> + <ul class="nav-links"> + <li><a href="#basics">Basics</a></li> + <li><a href="#techniques">Techniques</a></li> + <li><a href="#practice">Practice</a></li> + </ul> + </nav> +</header> + +<main> + <section class="hero"> + <h1>Master Sudoku Strategies</h1> + <p>Learn advanced techniques with interactive examples</p> + </section> + + <section id="basics" class="techniques-section"> + <h2>Basic Concepts</h2> + <div class="technique-grid"> + <div class="technique-card"> + <h3>Scanning</h3> + <div class="sudoku-mini-grid" data-technique="scanning"></div> + <p>Learn to efficiently scan rows, columns, and boxes to identify opportunities.</p> + </div> + <div class="technique-card"> + <h3>Pencil Marks</h3> + <div class="sudoku-mini-grid" data-technique="pencilmarks"></div> + <p>Master the art of noting possible numbers in each cell.</p> + </div> + </div> + </section> + + <section id="techniques" class="techniques-section"> + <h2>Advanced Techniques</h2> + <div class="technique-grid"> + <div class="technique-card"> + <h3>Hidden Pairs</h3> + <div class="sudoku-mini-grid" data-technique="hiddenpairs"></div> + <button class="demo-btn">Show Example</button> + </div> + <div class="technique-card"> + <h3>X-Wing</h3> + <div class="sudoku-mini-grid" data-technique="xwing"></div> + <button class="demo-btn">Show Example</button> + </div> + </div> + </section> + + <section id="practice" class="practice-section"> + <h2>Practice Grid</h2> + <div class="interactive-grid" id="practiceGrid"></div> + <div class="controls"> + <button id="newPuzzle">New Puzzle</button> + <button id="showHint">Show Hint</button> + <button id="checkSolution">Check Solution</button> + </div> + </section> +</main> + +<footer> + <p>Made with passion for Sudoku enthusiasts</p> + <nav> + <a href="#basics">Basics</a> + <a href="#techniques">Techniques</a> + <a href="#practice">Practice</a> + </nav> +</footer> diff --git a/index.scroll b/index.scroll new file mode 100644 index 0000000..992b0fa --- /dev/null +++ b/index.scroll @@ -0,0 +1,8 @@ +buildHtml +baseUrl https://sudokutips.scroll.pub +metaTags +editButton /edit.html +title Sudoku Tips - Learn Advanced Techniques & Strategies +style.css +body.html +script.js diff --git a/readme.scroll b/readme.scroll new file mode 100644 index 0000000..dce8005 --- /dev/null +++ b/readme.scroll @@ -0,0 +1,2 @@ +# sudokutips.scroll.pub +Website generated by Claude from prompt: Create a site to help me improve in sudoku by showing live playing tricks. \ No newline at end of file diff --git a/script.js b/script.js new file mode 100644 index 0000000..5fba86e --- /dev/null +++ b/script.js @@ -0,0 +1,72 @@ +document.addEventListener('DOMContentLoaded', () => { + // Mobile menu toggle + const menuToggle = document.querySelector('.menu-toggle'); + const navLinks = document.querySelector('.nav-links'); + + menuToggle.addEventListener('click', () => { + navLinks.classList.toggle('active'); + }); + + // Demo buttons functionality + const demoButtons = document.querySelectorAll('.demo-btn'); + demoButtons.forEach(btn => { + btn.addEventListener('click', () => { + const technique = btn.parentElement.querySelector('.sudoku-mini-grid'); + demonstrateTechnique(technique.dataset.technique); + }); + }); + + // Initialize practice grid + initializePracticeGrid(); +}); + +function demonstrateTechnique(technique) { + // Example demonstrations for each technique + const demonstrations = { + hiddenpairs: () => { + // Animation logic for hidden pairs technique + console.log('Demonstrating hidden pairs technique'); + }, + xwing: () => { + // Animation logic for x-wing technique + console.log('Demonstrating x-wing technique'); + } + }; + + if (demonstrations[technique]) { + demonstrations[technique](); + } +} + +function initializePracticeGrid() { + const grid = document.getElementById('practiceGrid'); + // Initialize 9x9 grid + for (let i = 0; i < 81; i++) { + const cell = document.createElement('input'); + cell.type = 'number'; + cell.min = 1; + cell.max = 9; + cell.classList.add('grid-cell'); + grid.appendChild(cell); + } + + // Add event listeners for control buttons + document.getElementById('newPuzzle').addEventListener('click', generateNewPuzzle); + document.getElementById('showHint').addEventListener('click', showHint); + document.getElementById('checkSolution').addEventListener('click', checkSolution); +} + +function generateNewPuzzle() { + // Generate new Sudoku puzzle + console.log('Generating new puzzle'); +} + +function showHint() { + // Show next best move + console.log('Showing hint'); +} + +function checkSolution() { + // Validate current grid state + console.log('Checking solution'); +} diff --git a/style.css b/style.css new file mode 100644 index 0000000..16d3cab --- /dev/null +++ b/style.css @@ -0,0 +1,190 @@ +:root { + --primary-color: #2c3e50; + --accent-color: #3498db; + --bg-color: #f9f9f9; + --text-color: #333; + --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); +} + +* { + margin: 0; + padding: 0; + box-sizing: border-box; +} + +body { + font-family: 'Segoe UI', system-ui, sans-serif; + line-height: 1.6; + color: var(--text-color); + background: var(--bg-color); +} + +header { + background: var(--primary-color); + padding: 1rem; + position: fixed; + width: 100%; + top: 0; + z-index: 1000; +} + +nav { + max-width: 1200px; + margin: 0 auto; + display: flex; + justify-content: space-between; + align-items: center; +} + +.logo { + color: white; + font-size: 1.5rem; + font-weight: bold; +} + +.nav-links { + display: flex; + gap: 2rem; + list-style: none; +} + +.nav-links a { + color: white; + text-decoration: none; + transition: color 0.3s; +} + +.nav-links a:hover { + color: var(--accent-color); +} + +main { + margin-top: 4rem; + padding: 2rem; +} + +.hero { + text-align: center; + padding: 4rem 2rem; + background: linear-gradient(135deg, var(--primary-color), var(--accent-color)); + color: white; + border-radius: 1rem; + margin-bottom: 3rem; +} + +.hero h1 { + font-size: 3rem; + margin-bottom: 1rem; +} + +.technique-grid { + display: grid; + grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); + gap: 2rem; + margin: 2rem 0; +} + +.technique-card { + background: white; + padding: 2rem; + border-radius: 1rem; + box-shadow: var(--card-shadow); + transition: transform 0.3s; +} + +.technique-card:hover { + transform: translateY(-5px); +} + +.sudoku-mini-grid { + width: 100%; + aspect-ratio: 1; + background: #eee; + margin: 1rem 0; + border-radius: 0.5rem; +} + +.demo-btn { + background: var(--accent-color); + color: white; + border: none; + padding: 0.5rem 1rem; + border-radius: 0.5rem; + cursor: pointer; + transition: background 0.3s; +} + +.demo-btn:hover { + background: var(--primary-color); +} + +.practice-section { + max-width: 600px; + margin: 4rem auto; +} + +.interactive-grid { + width: 100%; + aspect-ratio: 1; + background: white; + box-shadow: var(--card-shadow); + border-radius: 1rem; + margin: 2rem 0; +} + +.controls { + display: flex; + gap: 1rem; + justify-content: center; +} + +footer { + background: var(--primary-color); + color: white; + padding: 2rem; + text-align: center; + margin-top: 4rem; +} + +footer nav { + margin-top: 1rem; +} + +footer a { + color: white; + text-decoration: none; + margin: 0 1rem; +} + +@media (max-width: 768px) { + .menu-toggle { + display: flex; + flex-direction: column; + gap: 0.25rem; + cursor: pointer; + } + + .menu-toggle span { + display: block; + width: 25px; + height: 3px; + background: white; + border-radius: 3px; + } + + .nav-links { + display: none; + position: absolute; + top: 100%; + left: 0; + right: 0; + background: var(--primary-color); + padding: 1rem; + } + + .nav-links.active { + display: flex; + flex-direction: column; + align-items: center; + } +}