Spaces:
Runtime error
Runtime error
Download Stack/templates/stack.html from swetha-coding/dsahub: direct link, hf CLI and curl.
- Browser
- Download file 2.15 kB
-
https://huggingface.co/spaces/swetha-coding/dsahub/resolve/main/Stack/templates/stack.html
- Command line
-
hf download hf://spaces/swetha-coding/dsahub/Stack/templates/stack.html
-
curl -L -o stack.html https://huggingface.co/spaces/swetha-coding/dsahub/resolve/main/Stack/templates/stack.html
2.15 kB
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title>Stack Simulator</title> | |
| <!-- Bootstrap CSS --> | |
| <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> | |
| <link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}"> | |
| </head> | |
| <body class="bg-light"> | |
| <div class="container mt-5"> | |
| <div class="card shadow-sm"> | |
| <div class="card-header bg-primary text-white"> | |
| <h3 class="mb-0">Stack Simulator</h3> | |
| </div> | |
| <div class="card-body"> | |
| <!-- Stack Display --> | |
| <h5 class="mb-3">Current Stack:</h5> | |
| <ul class="list-group mb-3"> | |
| {% for item in stack %} | |
| <li class="list-group-item">{{ item }}</li> | |
| {% else %} | |
| <li class="list-group-item text-muted">Stack is empty</li> | |
| {% endfor %} | |
| </ul> | |
| <!-- Top Element --> | |
| {% if top %} | |
| <div class="alert alert-info"> | |
| Top element: <strong>{{ top }}</strong> | |
| </div> | |
| {% endif %} | |
| <!-- Push Form --> | |
| <form action="/stack/push" method="post" class="d-flex mb-3"> | |
| <input type="text" name="item" class="form-control me-2" placeholder="Enter item"> | |
| <button type="submit" class="btn btn-success">Push</button> | |
| </form> | |
| <!-- Action Buttons --> | |
| <div class="d-flex gap-2"> | |
| <a href="/stack/pop" class="btn btn-danger">Pop</a> | |
| <a href="/stack/peek" class="btn btn-warning">Peek</a> | |
| </div> | |
| <div class="mt-3"> | |
| <a href="/" class="btn btn-secondary">Back to Hub</a> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Bootstrap JS --> | |
| <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script> | |
| </body> | |
| </html> | |