uppy/examples/transloadit-textarea/index.html
github-actions[bot] b9ecd94ecd
Release: uppy@2.6.0 (#3501)
| Package         | Version | Package         | Version |
| --------------- | ------- | --------------- | ------- |
| @uppy/companion |   3.3.0 | uppy            |   2.6.0 |
| @uppy/robodog   |   2.3.2 |                 |         |

- meta: warn about not merging PR manually (Artur Paikin / #3492)
- @uppy/companion: fix unpslash author meta, sanitize metadata to strings and improve companion tests (Mikael Finstad / #3478)
- meta: ensure README is correctly formatted when doing releases (Antoine du Hamel / #3499)
- meta: fix CDN bundle (Antoine du Hamel / #3494)
- meta: fix missing EOL and end of e2e test templates (Antoine du Hamel / #3484)
- meta: use a single `.env` file for config (Antoine du Hamel / #3498)
2022-02-17 19:55:12 +00:00

144 lines
3.9 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="https://releases.transloadit.com/uppy/robodog/v2.3.2/robodog.css">
<style>
body {
font-family: Roboto, Open Sans;
background: #f4f5f6;
}
h1, h2, h3, h4, h5, h6 {
font-family: Oxygen, Raleway, Open Sans;
}
header {
width: 800px;
margin: auto;
}
header h1 { text-align: center; }
main {
background: white;
margin: auto;
width: 800px;
border: 2px solid #e8eaee;
padding: 36px;
border-radius: 5px;
}
main p:first-child { margin-top: 0 }
label {
display: flex;
padding-bottom: 16px;
border-bottom: 1px solid #e8eaee;
margin-bottom: 16px;
}
.label-text {
width: 25%;
text-transform: uppercase;
color: #888888;
line-height: 34px;
}
label input, label textarea {
flex-grow: 1;
height: 34px;
}
label textarea {
box-sizing: border-box;
padding: 6px;
border-radius: 5px;
border: 1px solid #b7b7b4;
font-family: Roboto, Open Sans;
min-height: 160px;
width: 100%;
resize: vertical;
}
.form-createSnippet {
border: 1px solid #2e6da4;
border-bottom-width: 3px;
padding: 8px;
border-radius: 5px;
background-color: #337ab7;
color: white;
width: 100%;
}
.mdtxt {
width: 100%;
height: 100%;
}
.mdtxt-controls {
}
.mdtxt-upload {
box-sizing: border-box;
width: 100%;
border-radius: 0 0 5px 5px;
border: 1px solid #b7b7b4;
border-top-width: 0;
padding: 4px 8px;
cursor: pointer;
}
.mdtxt textarea {
margin-bottom: 0;
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
.mdtxt-upload .error {
border-color: red;
color: red;
}
.mdtxt-upload .error .message {
margin-right: 8px;
}
.snippet {
margin-top: 25px;
}
</style>
</head>
<body>
<header>
<h1>Markdown Bin</h1>
</header>
<main>
<p>
Markdown Bin is a demo app that works a bit like Github Gists or pastebin. You can add markdown snippets, and add file attachments to each snippet by clicking "Upload an attachment" or by dragging files onto the text area. Transloadit generates an inline preview image for images, videos, and audio files. <a target="_blank" href="https://github.com/transloadit/uppy/blob/main/examples/transloadit-textarea/template.json">&raquo;&nbsp;View the Assembly Template here.</a>
</p>
<p>
⚠️ For this demo, snippets are stored locally in your browser. Attachments are stored in Transloadit's temporary storage and expire after about 24 hours. In a real app, you can easily export files to a permanent storage solution like Amazon S3 or Google Cloud. <a target="_blank" href="https://transloadit.com/docs/#17-saving-conversion-results">&raquo;&nbsp;Learn more</a>
</p>
<form id="new">
<h2>Create a new snippet</h2>
<label>
<span class="label-text">Snippet Title</span>
<input type="text" name="title" placeholder="Snippet Title">
</label>
<label>
<textarea name="snippet"></textarea>
</label>
<p>
<button class="form-createSnippet" type="submit">
Create
</button>
</p>
</form>
<h2>Previous snippets</h2>
<div id="snippets">
</div>
</main>
<template id="snippet">
<div class="snippet">
<h3 class="snippet-title"></h3>
<div class="snippet-content"></div>
</div>
</template>
<script src="bundle.js"></script>
</body>
</html>