2021-01-17 20:09:57 +00:00
|
|
|
{{define "index"}}
|
|
|
|
<!DOCTYPE html>
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<meta charset="utf-8" />
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
|
|
<title>Translate</title>
|
|
|
|
<link rel="stylesheet" href="/static/style.css" />
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<h1 class="title">Translate</h1>
|
|
|
|
|
2021-01-18 18:59:14 +00:00
|
|
|
<section class="main-section">
|
|
|
|
<form action="/" method="POST" class="form">
|
|
|
|
<div class="form__field">
|
|
|
|
<label for="from" class="item form__label">
|
|
|
|
Source language:
|
|
|
|
</label>
|
|
|
|
<input class="form__input" name="from" placeholder="en,de" value="{{.From}}">
|
|
|
|
</div>
|
2021-01-17 20:09:57 +00:00
|
|
|
|
2021-01-18 18:59:14 +00:00
|
|
|
<div class="form__field">
|
|
|
|
<label for="to" class="item form__label">
|
|
|
|
Translate to:
|
|
|
|
</label>
|
|
|
|
<input class="form__input" name="to" placeholder="fr,ru" value="{{.To}}">
|
|
|
|
</div>
|
2021-01-17 20:09:57 +00:00
|
|
|
|
2021-01-18 18:59:14 +00:00
|
|
|
<div class="form__field">
|
|
|
|
<textarea name="text" class="textarea" placeholder="Text to translate">{{.Text}}</textarea>
|
|
|
|
</div>
|
2021-01-17 20:09:57 +00:00
|
|
|
|
2021-01-18 18:59:14 +00:00
|
|
|
<div class="form__field">
|
|
|
|
<button type="submit" class="form__button">Translate!</button>
|
|
|
|
</div>
|
|
|
|
</form>
|
2021-01-17 20:09:57 +00:00
|
|
|
|
2021-01-18 18:59:14 +00:00
|
|
|
<pre class="translation">{{.Translation}}</pre>
|
|
|
|
</section>
|
2021-01-17 20:09:57 +00:00
|
|
|
</body>
|
|
|
|
</html>
|
|
|
|
{{end}}
|