commit ff1eeeab4228ada4acd0e58d3643575d4fa3757c
Author: root <root@hub.scroll.pub>
Date: 2024-12-29 08:48:34 +0000
Subject: Initial commit
diff --git a/body.html b/body.html
new file mode 100644
index 0000000..a4e3bd6
--- /dev/null
+++ b/body.html
@@ -0,0 +1,27 @@
+<header>
+ <h1>Sign Up for Our Event</h1>
+ <p>Join us for an exciting event! Please fill out the form below to register.</p>
+</header>
+<main>
+ <form id="signupForm">
+ <div class="form-group">
+ <label for="name">Name:</label>
+ <input type="text" id="name" name="name" required>
+ </div>
+ <div class="form-group">
+ <label for="phone">Phone:</label>
+ <input type="tel" id="phone" name="phone" required>
+ <small>Format: 123-456-7890</small>
+ </div>
+ <div class="form-group">
+ <label for="email">Company Email:</label>
+ <input type="email" id="email" name="email" required>
+ <small>Only company emails allowed (e.g., yourname@company.com)</small>
+ </div>
+ <button type="submit">Submit</button>
+ </form>
+ <div id="message"></div>
+</main>
+<footer>
+ <p>We look forward to seeing you at the event!</p>
+</footer>
\ No newline at end of file
diff --git a/index.scroll b/index.scroll
new file mode 100644
index 0000000..66524dc
--- /dev/null
+++ b/index.scroll
@@ -0,0 +1,8 @@
+buildHtml
+baseUrl https://signup.scroll.pub
+metaTags
+editButton /edit.html
+title Sign Up for Our Event
+style.css
+body.html
+script.js
\ No newline at end of file
diff --git a/prompt.json b/prompt.json
new file mode 100644
index 0000000..16c4944
--- /dev/null
+++ b/prompt.json
@@ -0,0 +1,25 @@
+{
+ "id": "57e001f2-9a64-4315-bed8-3ef5c4399e06",
+ "object": "chat.completion",
+ "created": 1735462097,
+ "model": "deepseek-chat",
+ "choices": [
+ {
+ "index": 0,
+ "message": {
+ "role": "assistant",
+ "content": "---domain---\nsignup.scroll.pub\n---index.scroll---\nbuildHtml\nbaseUrl https://signup.scroll.pub\nmetaTags\neditButton /edit.html\ntitle Sign Up for Our Event\nstyle.css\nbody.html\nscript.js\n---body.html---\n<header>\n <h1>Sign Up for Our Event</h1>\n <p>Join us for an exciting event! Please fill out the form below to register.</p>\n</header>\n<main>\n <form id=\"signupForm\">\n <div class=\"form-group\">\n <label for=\"name\">Name:</label>\n <input type=\"text\" id=\"name\" name=\"name\" required>\n </div>\n <div class=\"form-group\">\n <label for=\"phone\">Phone:</label>\n <input type=\"tel\" id=\"phone\" name=\"phone\" required>\n <small>Format: 123-456-7890</small>\n </div>\n <div class=\"form-group\">\n <label for=\"email\">Company Email:</label>\n <input type=\"email\" id=\"email\" name=\"email\" required>\n <small>Only company emails allowed (e.g., yourname@company.com)</small>\n </div>\n <button type=\"submit\">Submit</button>\n </form>\n <div id=\"message\"></div>\n</main>\n<footer>\n <p>We look forward to seeing you at the event!</p>\n</footer>\n---style.css---\nbody {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n margin: 0;\n padding: 0;\n background-color: #f4f4f9;\n color: #333;\n line-height: 1.6;\n}\n\nheader {\n background-color: #6200ea;\n color: white;\n padding: 2rem;\n text-align: center;\n}\n\nheader h1 {\n margin: 0;\n font-size: 2.5rem;\n}\n\nheader p {\n margin: 0.5rem 0 0;\n font-size: 1.2rem;\n}\n\nmain {\n padding: 2rem;\n max-width: 600px;\n margin: 0 auto;\n}\n\nform {\n background: white;\n padding: 2rem;\n border-radius: 8px;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);\n}\n\n.form-group {\n margin-bottom: 1.5rem;\n}\n\nlabel {\n display: block;\n margin-bottom: 0.5rem;\n font-weight: bold;\n}\n\ninput {\n width: 100%;\n padding: 0.75rem;\n border: 1px solid #ddd;\n border-radius: 4px;\n font-size: 1rem;\n}\n\ninput:focus {\n border-color: #6200ea;\n outline: none;\n}\n\nsmall {\n display: block;\n margin-top: 0.25rem;\n color: #666;\n}\n\nbutton {\n background-color: #6200ea;\n color: white;\n padding: 0.75rem 1.5rem;\n border: none;\n border-radius: 4px;\n font-size: 1rem;\n cursor: pointer;\n transition: background-color 0.3s ease;\n}\n\nbutton:hover {\n background-color: #3700b3;\n}\n\n#message {\n margin-top: 1.5rem;\n padding: 1rem;\n border-radius: 4px;\n text-align: center;\n}\n\nfooter {\n text-align: center;\n padding: 1rem;\n background-color: #333;\n color: white;\n margin-top: 2rem;\n}\n\n@media (max-width: 600px) {\n header h1 {\n font-size: 2rem;\n }\n\n header p {\n font-size: 1rem;\n }\n\n main {\n padding: 1rem;\n }\n\n form {\n padding: 1rem;\n }\n}\n---script.js---\ndocument.getElementById('signupForm').addEventListener('submit', function(event) {\n event.preventDefault();\n\n const name = document.getElementById('name').value.trim();\n const phone = document.getElementById('phone').value.trim();\n const email = document.getElementById('email').value.trim();\n\n const phonePattern = /^\\d{3}-\\d{3}-\\d{4}$/;\n const emailPattern = /^[a-zA-Z0-9._%+-]+@(?!.*(qq\\.com|163\\.com|gmail\\.com))[a-zA-Z0-9.-]+\\.[a-zA-Z]{2,}$/;\n\n let message = '';\n\n if (!name) {\n message = 'Please enter your name.';\n } else if (!phonePattern.test(phone)) {\n message = 'Please enter a valid phone number (e.g., 123-456-7890).';\n } else if (!emailPattern.test(email)) {\n message = 'Please enter a valid company email address.';\n } else {\n message = 'Thank you for signing up! We will contact you soon.';\n document.getElementById('signupForm').reset();\n }\n\n document.getElementById('message').textContent = message;\n});\n---end---"
+ },
+ "logprobs": null,
+ "finish_reason": "stop"
+ }
+ ],
+ "usage": {
+ "prompt_tokens": 278,
+ "completion_tokens": 1146,
+ "total_tokens": 1424,
+ "prompt_cache_hit_tokens": 0,
+ "prompt_cache_miss_tokens": 278
+ },
+ "system_fingerprint": "fp_f1afce2943"
+}
\ No newline at end of file
diff --git a/readme.scroll b/readme.scroll
new file mode 100644
index 0000000..3deb1c9
--- /dev/null
+++ b/readme.scroll
@@ -0,0 +1,2 @@
+# signup.scroll.pub
+Website generated by DeepSeek from prompt: 创建一个报名网站,有三个选项需要填写:姓名、电话以及公司邮箱,其中电话和公司邮箱都需要做格式的验证,邮箱不允许 qq.com,163.com,gmail.com 等非商业邮箱
\ No newline at end of file
diff --git a/script.js b/script.js
new file mode 100644
index 0000000..22f160c
--- /dev/null
+++ b/script.js
@@ -0,0 +1,25 @@
+document.getElementById('signupForm').addEventListener('submit', function(event) {
+ event.preventDefault();
+
+ const name = document.getElementById('name').value.trim();
+ const phone = document.getElementById('phone').value.trim();
+ const email = document.getElementById('email').value.trim();
+
+ const phonePattern = /^\d{3}-\d{3}-\d{4}$/;
+ const emailPattern = /^[a-zA-Z0-9._%+-]+@(?!.*(qq\.com|163\.com|gmail\.com))[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
+
+ let message = '';
+
+ if (!name) {
+ message = 'Please enter your name.';
+ } else if (!phonePattern.test(phone)) {
+ message = 'Please enter a valid phone number (e.g., 123-456-7890).';
+ } else if (!emailPattern.test(email)) {
+ message = 'Please enter a valid company email address.';
+ } else {
+ message = 'Thank you for signing up! We will contact you soon.';
+ document.getElementById('signupForm').reset();
+ }
+
+ document.getElementById('message').textContent = message;
+});
\ No newline at end of file
diff --git a/style.css b/style.css
new file mode 100644
index 0000000..6bc539a
--- /dev/null
+++ b/style.css
@@ -0,0 +1,115 @@
+body {
+ font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
+ margin: 0;
+ padding: 0;
+ background-color: #f4f4f9;
+ color: #333;
+ line-height: 1.6;
+}
+
+header {
+ background-color: #6200ea;
+ color: white;
+ padding: 2rem;
+ text-align: center;
+}
+
+header h1 {
+ margin: 0;
+ font-size: 2.5rem;
+}
+
+header p {
+ margin: 0.5rem 0 0;
+ font-size: 1.2rem;
+}
+
+main {
+ padding: 2rem;
+ max-width: 600px;
+ margin: 0 auto;
+}
+
+form {
+ background: white;
+ padding: 2rem;
+ border-radius: 8px;
+ box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
+}
+
+.form-group {
+ margin-bottom: 1.5rem;
+}
+
+label {
+ display: block;
+ margin-bottom: 0.5rem;
+ font-weight: bold;
+}
+
+input {
+ width: 100%;
+ padding: 0.75rem;
+ border: 1px solid #ddd;
+ border-radius: 4px;
+ font-size: 1rem;
+}
+
+input:focus {
+ border-color: #6200ea;
+ outline: none;
+}
+
+small {
+ display: block;
+ margin-top: 0.25rem;
+ color: #666;
+}
+
+button {
+ background-color: #6200ea;
+ color: white;
+ padding: 0.75rem 1.5rem;
+ border: none;
+ border-radius: 4px;
+ font-size: 1rem;
+ cursor: pointer;
+ transition: background-color 0.3s ease;
+}
+
+button:hover {
+ background-color: #3700b3;
+}
+
+#message {
+ margin-top: 1.5rem;
+ padding: 1rem;
+ border-radius: 4px;
+ text-align: center;
+}
+
+footer {
+ text-align: center;
+ padding: 1rem;
+ background-color: #333;
+ color: white;
+ margin-top: 2rem;
+}
+
+@media (max-width: 600px) {
+ header h1 {
+ font-size: 2rem;
+ }
+
+ header p {
+ font-size: 1rem;
+ }
+
+ main {
+ padding: 1rem;
+ }
+
+ form {
+ padding: 1rem;
+ }
+}
\ No newline at end of file