-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
69 lines (69 loc) · 2.11 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title>Wichteln</title>
<link rel="stylesheet" href="style.css"/>
<script>
;(colorScheme => ['dark', 'light'].forEach(scheme => {
if (colorScheme === scheme) {
document.querySelector('html').classList.add(scheme)
}
}))(localStorage.getItem('color-scheme'))
</script>
</head>
<body class="loading">
<div id="app">
<p>
<a href="javascript:;" @click="selectLanguage('de')">Deutsch</a>
{{' '}}
<a href="javascript:;" @click="selectLanguage('en')">English</a>
</p>
<h1>{{locale.title}}</h1>
<p>{{locale.introText}}</p>
<p>
<div class="row">
<text-field :label="locale.secret" v-model="data.secret"></text-field>
<button @click="randomSecret()">{{locale.random}}</button>
</div>
</p>
<p>{{locale.publicText}}</p>
<p>{{public}}</p>
<h2>{{locale.participants}}</h2>
<div class="form" v-for="(participant, i) in data.participants" :key="i">
<div class="row">
<text-field :label="locale.nickname" :error="nicknameErrors[i] ? locale.nicknamesUnique : null" v-model="participant.nickname"></text-field>
<button @click="removeParticipant(i)">{{locale.remove}}</button>
</div>
<div class="row">
<text-field :label="locale.email" v-model="participant.email"></text-field>
</div>
<div class="row">
<text-area :label="locale.address" v-model="participant.address"></text-area>
</div>
</div>
<p>
<button @click="addParticipant()">{{locale.newParticipant}}</button>
</p>
<h2>{{locale.email}}</h2>
<p>{{locale.emailIntro}}</p>
<p>{{locale.emailPlaceholders}}</p>
<div class="form">
<div class="row">
<text-field :label="locale.subject" v-model="data.email.subject"></text-field>
</div>
<div class="row">
<text-area :label="locale.body" v-model="data.email.body"></text-area>
</div>
</div>
<p>{{locale.emailLinks}}</p>
<p>
<template v-for="(mail, i) in mails" :key="i">
{{i > 0 ? ' ' : ''}}<a :href="mail.mail">{{mail.nickname}}</a>
</template>
</p>
</div>
<script src="vue.global.prod.js"></script>
<script src="app.js"></script>
</body>
</html>