Rebrand to GlitchCraft with IPv6 support
Changes: - Renamed from "Text Corruptor" to "GlitchCraft" - New slogan: "Artisanal text corruption, served fresh!" - Updated server to support both IPv4 and IPv6 (dual-stack) - Server now listens on all interfaces (::) instead of just localhost - Updated all references in code and documentation The new name reflects both the glitch aesthetic and the craftsmanship of creating beautifully corrupted text, with a playful tone. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
44a2ac4cbd
commit
4e58281d51
7 changed files with 38 additions and 16 deletions
|
|
@ -4,7 +4,7 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
|
|||
|
||||
## Project Overview
|
||||
|
||||
Text Corruptor is a Progressive Web App (PWA) that generates zalgo text (corrupted/glitched text using Unicode combining characters). The app features real-time text corruption with adjustable intensity and click-to-copy functionality.
|
||||
GlitchCraft is a Progressive Web App (PWA) that generates zalgo text (corrupted/glitched text using Unicode combining characters). The app features real-time text corruption with adjustable intensity and click-to-copy functionality.
|
||||
|
||||
## Project Structure
|
||||
|
||||
|
|
@ -31,7 +31,7 @@ zalgo/
|
|||
|
||||
### Running the Application
|
||||
```bash
|
||||
# Start development server (serves on http://localhost:8000/)
|
||||
# Start development server (serves on http://localhost:8000/ and [::]:8000)
|
||||
python3 server.py
|
||||
|
||||
# Or using the npm script
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/**
|
||||
* Main application logic for Text Corruptor
|
||||
* Main application logic for GlitchCraft
|
||||
* Handles UI interactions and PWA registration
|
||||
*/
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<title>Generate PWA Icons</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Icon Generator for Text Corruptor</h1>
|
||||
<h1>Icon Generator for GlitchCraft</h1>
|
||||
<p>Right-click each canvas and save as PNG to the icons folder</p>
|
||||
|
||||
<div id="canvases"></div>
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
content="Transform your text into corrupted zalgo text with one click. Perfect for creating glitchy, distorted text effects."
|
||||
/>
|
||||
<meta name="theme-color" content="#1a1a2e" />
|
||||
<title>Text Corruptor - Zalgo Text Generator</title>
|
||||
<title>GlitchCraft - Artisanal Text Corruption</title>
|
||||
<link rel="manifest" href="manifest.json" />
|
||||
<link rel="icon" type="image/png" sizes="192x192" href="icons/icon-192.png" />
|
||||
<link rel="icon" type="image/png" sizes="512x512" href="icons/icon-512.png" />
|
||||
|
|
@ -18,8 +18,8 @@
|
|||
<body>
|
||||
<div class="container">
|
||||
<header>
|
||||
<h1>Text Corruptor</h1>
|
||||
<p class="subtitle">Transform your text into corrupted chaos</p>
|
||||
<h1>GlitchCraft</h1>
|
||||
<p class="subtitle">Artisanal text corruption, served fresh!</p>
|
||||
</header>
|
||||
|
||||
<main>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "Text Corruptor - Zalgo Text Generator",
|
||||
"short_name": "Text Corruptor",
|
||||
"description": "Transform your text into corrupted zalgo text with adjustable intensity",
|
||||
"name": "GlitchCraft - Artisanal Text Corruption",
|
||||
"short_name": "GlitchCraft",
|
||||
"description": "Artisanal text corruption, served fresh! Create beautifully chaotic zalgo text with adjustable intensity",
|
||||
"start_url": "/",
|
||||
"display": "standalone",
|
||||
"background_color": "#0f0f14",
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
/**
|
||||
* Service Worker for Text Corruptor PWA
|
||||
* Service Worker for GlitchCraft PWA
|
||||
* Enables offline functionality and caching
|
||||
*/
|
||||
|
||||
const CACHE_NAME = 'text-corruptor-v1';
|
||||
const CACHE_NAME = 'glitchcraft-v1';
|
||||
const urlsToCache = ['/', '/index.html', '/styles.css', '/zalgo.js', '/app.js', '/manifest.json'];
|
||||
|
||||
// Install event - cache essential files
|
||||
|
|
|
|||
30
server.py
30
server.py
|
|
@ -1,12 +1,13 @@
|
|||
#!/usr/bin/env python3
|
||||
"""
|
||||
Simple HTTP server for testing the Text Corruptor PWA
|
||||
Simple HTTP server for testing the GlitchCraft PWA
|
||||
Run with: python3 server.py
|
||||
Then open http://localhost:8000/ in your browser
|
||||
"""
|
||||
|
||||
import http.server
|
||||
import socketserver
|
||||
import socket
|
||||
import os
|
||||
|
||||
PORT = 8000
|
||||
|
|
@ -14,8 +15,21 @@ PORT = 8000
|
|||
DIRECTORY = os.path.join(os.path.dirname(os.path.abspath(__file__)), "app")
|
||||
|
||||
|
||||
class DualStackServer(socketserver.TCPServer):
|
||||
"""TCP server that supports both IPv4 and IPv6."""
|
||||
|
||||
address_family = socket.AF_INET6
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
# Disable dual stack to make it work on all systems
|
||||
# Some systems have it enabled by default, some don't
|
||||
super().__init__(*args, **kwargs)
|
||||
# Enable dual stack - listen on both IPv4 and IPv6
|
||||
self.socket.setsockopt(socket.IPPROTO_IPV6, socket.IPV6_V6ONLY, 0)
|
||||
|
||||
|
||||
class MyHTTPRequestHandler(http.server.SimpleHTTPRequestHandler):
|
||||
"""Custom HTTP request handler for serving the Text Corruptor PWA."""
|
||||
"""Custom HTTP request handler for serving the GlitchCraft PWA."""
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
super().__init__(*args, directory=DIRECTORY, **kwargs)
|
||||
|
|
@ -29,8 +43,16 @@ class MyHTTPRequestHandler(http.server.SimpleHTTPRequestHandler):
|
|||
|
||||
|
||||
if __name__ == "__main__":
|
||||
with socketserver.TCPServer(("", PORT), MyHTTPRequestHandler) as httpd:
|
||||
print(f"Server running at http://localhost:{PORT}/")
|
||||
# Listen on all interfaces (:: for IPv6, which also handles IPv4 with dual stack)
|
||||
HOST = "::" # Listen on all interfaces (IPv6 and IPv4)
|
||||
|
||||
with DualStackServer((HOST, PORT), MyHTTPRequestHandler) as httpd:
|
||||
print(f"Server running on all interfaces at port {PORT}")
|
||||
print(f"Access at:")
|
||||
print(f" http://localhost:{PORT}/")
|
||||
print(f" http://127.0.0.1:{PORT}/ (IPv4)")
|
||||
print(f" http://[::1]:{PORT}/ (IPv6)")
|
||||
print(f" http://<your-ip>:{PORT}/")
|
||||
print(f"Serving files from: {DIRECTORY}")
|
||||
print("Press Ctrl+C to stop the server")
|
||||
try:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue