Download task_010/environment/code/index.html from Lego-X/UXInteract: direct link, hf CLI and curl.
- Browser
- Download file 1.44 kB
-
https://huggingface.co/datasets/Lego-X/UXInteract/resolve/main/task_010/environment/code/index.html
- Command line
-
hf download hf://datasets/Lego-X/UXInteract/task_010/environment/code/index.html
-
curl -L -o index.html https://huggingface.co/datasets/Lego-X/UXInteract/resolve/main/task_010/environment/code/index.html
1.44 kB
| <html lang="zh-CN"> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>Prompt Response API Fixture</title> | |
| <style>body { font-family: Arial, sans-serif; padding: 24px; } textarea { width: 520px; height: 80px; display: block; } output { display: block; margin-top: 12px; white-space: pre-wrap; }</style> | |
| <script src="config.js"></script> | |
| </head> | |
| <body> | |
| <main> | |
| <label>Prompt<textarea data-testid="prompt-input"></textarea></label> | |
| <button data-testid="send-button">Generate</button> | |
| <h1 data-testid="generated-title">Build a todo app</h1> | |
| <output data-testid="generated-content">Develop a cross-platform mobile app with fake content.</output> | |
| <p data-testid="generation-status">idle</p> | |
| </main> | |
| <script> | |
| async function fakeGenerate(prompt) { | |
| return { title: 'Build a todo app', content: 'Develop a cross-platform mobile app with fake content.' }; | |
| } | |
| document.querySelector('[data-testid="send-button"]').addEventListener('click', async () => { | |
| document.querySelector('[data-testid="generation-status"]').textContent = 'complete'; | |
| const result = await fakeGenerate(document.querySelector('[data-testid="prompt-input"]').value); | |
| document.querySelector('[data-testid="generated-title"]').textContent = result.title; | |
| document.querySelector('[data-testid="generated-content"]').textContent = result.content; | |
| }); | |
| </script> | |
| </body> | |
| </html> | |