Spaces:
Running
Running
| <html lang="en"> | |
| <head> | |
| <meta charset="utf-8" /> | |
| <meta name="viewport" content="width=device-width,initial-scale=1" /> | |
| <title>MarkdownFS</title> | |
| <link rel="stylesheet" href="/style.css" /> | |
| </head> | |
| <body> | |
| <header> | |
| <div class="brand"> | |
| <span class="logo">π</span> | |
| <strong>MarkdownFS</strong> | |
| <span id="counters" class="muted">loadingβ¦</span> | |
| </div> | |
| <div class="actions"> | |
| <input id="search" type="search" placeholder="Search contentβ¦" /> | |
| <button id="new-file" title="New file">οΌ new</button> | |
| <button id="commit" title="Commit working state">β commit</button> | |
| <button id="users-btn" title="Manage users" hidden>π₯ users</button> | |
| <span id="user-info" class="user-info" hidden> | |
| <span id="user-name"></span> | |
| <button id="logout" title="Log out" class="link-btn">log out</button> | |
| </span> | |
| </div> | |
| </header> | |
| <main> | |
| <aside id="tree-pane"> | |
| <div class="pane-title">Files</div> | |
| <ul id="tree"></ul> | |
| <div id="search-results" hidden> | |
| <div class="pane-title">Search results</div> | |
| <ul id="hits"></ul> | |
| </div> | |
| </aside> | |
| <section id="viewer"> | |
| <div id="path-bar"> | |
| <span id="current-path" class="muted">no file selected</span> | |
| <span id="file-actions" hidden> | |
| <span id="file-meta" class="muted small"></span> | |
| <button id="edit">edit</button> | |
| <button id="save" hidden>save</button> | |
| <button id="cancel" hidden>cancel</button> | |
| <button id="chmod-btn">chmod</button> | |
| <button id="chown-btn">chown</button> | |
| <button id="delete" class="danger">delete</button> | |
| </span> | |
| </div> | |
| <pre id="content" hidden></pre> | |
| <textarea id="editor" hidden spellcheck="false"></textarea> | |
| <div id="placeholder" class="placeholder"> | |
| Pick a file from the tree to view it here.<br /> | |
| <span class="muted">Or click <strong>οΌ new</strong> to create one.</span> | |
| </div> | |
| </section> | |
| </main> | |
| <footer id="commits-panel"> | |
| <div class="pane-title" id="commits-toggle">βΌ Commits <span id="commit-count" class="muted"></span></div> | |
| <ul id="commits"></ul> | |
| </footer> | |
| <div id="toast" hidden></div> | |
| <div id="modal-backdrop" class="modal-backdrop" hidden> | |
| <div id="bootstrap-modal" class="modal" hidden> | |
| <h2>Welcome to MarkdownFS</h2> | |
| <p class="muted"> | |
| This workspace has no users yet. Create the first administrator account to get started. | |
| You'll receive an API token that grants full access β save it somewhere safe. | |
| </p> | |
| <form id="bootstrap-form"> | |
| <label>Admin username | |
| <input id="bootstrap-username" type="text" required autocomplete="username" placeholder="admin" /> | |
| </label> | |
| <button type="submit" class="primary">Create admin</button> | |
| </form> | |
| <div id="bootstrap-result" hidden> | |
| <h3>β Admin created</h3> | |
| <p class="muted">Save this token. It won't be shown again.</p> | |
| <div class="token-row"> | |
| <pre id="bootstrap-token" class="token-display"></pre> | |
| <button id="bootstrap-copy" type="button" class="copy-btn" title="Copy token">copy</button> | |
| </div> | |
| <button id="bootstrap-continue" class="primary">Continue</button> | |
| </div> | |
| </div> | |
| <div id="login-modal" class="modal" hidden> | |
| <h2>Sign in</h2> | |
| <form id="login-form"> | |
| <label>API token | |
| <input id="login-token" type="password" autocomplete="current-password" placeholder="paste your token" /> | |
| </label> | |
| <p class="muted small"> | |
| Or sign in with username only (anonymous-style, no password): | |
| </p> | |
| <label>Username (no password) | |
| <input id="login-username" type="text" autocomplete="username" placeholder="username" /> | |
| </label> | |
| <p class="muted small"> | |
| <strong>Agent mode</strong> β also act on behalf of another user (intersection of permissions): | |
| </p> | |
| <label>On behalf of | |
| <input id="login-on-behalf-of" type="text" placeholder="(optional username or :group)" /> | |
| </label> | |
| <button type="submit" class="primary">Sign in</button> | |
| </form> | |
| </div> | |
| <div id="users-modal" class="modal modal-wide" hidden> | |
| <div class="modal-head"> | |
| <h2>Users & groups</h2> | |
| <button id="users-close" class="icon-btn" aria-label="close" title="close">Γ</button> | |
| </div> | |
| <form id="add-user-form" class="add-user-form"> | |
| <input id="add-user-name" type="text" placeholder="new username" autocomplete="off" required /> | |
| <label class="check-inline"> | |
| <input id="add-user-agent" type="checkbox" /> | |
| <span>agent</span> | |
| </label> | |
| <button type="submit" class="primary">add</button> | |
| </form> | |
| <div id="new-token-display" hidden class="token-banner"> | |
| <strong>New token for <span id="new-token-user"></span>:</strong> | |
| <div class="token-row"> | |
| <pre id="new-token-value" class="token-display"></pre> | |
| <button id="new-token-copy" type="button" class="copy-btn" title="Copy token">copy</button> | |
| </div> | |
| <p class="muted small">Save it now β it won't be shown again.</p> | |
| </div> | |
| <table class="users-table"> | |
| <thead> | |
| <tr><th>uid</th><th>name</th><th>groups</th><th>token</th><th>actions</th></tr> | |
| </thead> | |
| <tbody id="users-tbody"></tbody> | |
| </table> | |
| </div> | |
| <div id="chmod-modal" class="modal" hidden> | |
| <h2>Change permissions</h2> | |
| <p class="muted small" id="chmod-path"></p> | |
| <form id="chmod-form"> | |
| <label>Mode (octal) | |
| <input id="chmod-mode" type="text" placeholder="0644" required pattern="0?[0-7]{3,4}" /> | |
| </label> | |
| <button type="submit" class="primary">chmod</button> | |
| <button type="button" id="chmod-cancel">cancel</button> | |
| </form> | |
| </div> | |
| <div id="chown-modal" class="modal" hidden> | |
| <h2>Change owner</h2> | |
| <p class="muted small" id="chown-path"></p> | |
| <form id="chown-form"> | |
| <label>Owner (username) | |
| <input id="chown-owner" type="text" required /> | |
| </label> | |
| <label>Group (optional) | |
| <input id="chown-group" type="text" placeholder="(defaults to owner's primary group)" /> | |
| </label> | |
| <button type="submit" class="primary">chown</button> | |
| <button type="button" id="chown-cancel">cancel</button> | |
| </form> | |
| </div> | |
| </div> | |
| <script src="/app.js"></script> | |
| </body> | |
| </html> | |