intended-server/views/app/send.ejs

71 lines
2.1 KiB
Plaintext

<!DOCTYPE html>
<html lang="en">
<%- include('../layout/head.ejs', { title: 'Intended Link' }) %>
<script async src="/static/js/es-module-shims.js"></script>
<script type="importmap">
{
"imports": {
"/utils": "/static/js/utils.js",
"/send": "/static/js/send.js"
}
}
</script>
<body id="send-page">
<%- include('../layout/header.ejs') %>
<main class="f-col">
<div class="page-wrapper">
<div class="text-center">
<h1 class="page-header">Securely Share Your Secrets</h1>
<p>Only the person with the account you specify will be able to decrypt your message.</p>
</div>
<form id="secretForm" class="table rows">
<p>
<label for="text">Secret Message</label>
<textarea id="text" name="text" placeholder="Enter your secret here." required></textarea>
</p>
<p>
<label for="file">Or select your secret file</label>
<input type="file" id="file" name="file">
</p>
<p>
<label for="serviceIdentifier">Their Username / Email</label>
<input type="text" id="serviceIdentifier" name="serviceIdentifier" required>
</p>
<p>
<label for="github">Type of account:</label>
<select id="service" name="service">
<option value="github">Github</option>
<option value="google">Google</option>
</select>
</p>
<p>
<button type="submit">Generate URL</button>
</p>
</form>
<div class="result-section">
<div class="f-row">
<label for="result">Intended Link:</label>
<input type="text" id="result" readonly>
<button id="copyButton" class="iconbutton" type="button">⎘</button>
</div>
<div>
<label for="encryptedData">Encrypted data sent to the server:</label>
<textarea id="encryptedData" readonly></textarea>
</div>
</div>
</div>
</main>
<script type="module">
import { initializeSendPage } from '/send';
initializeSendPage();
</script>
<%- include('../layout/footer.ejs') %>
</body>
</html>