-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
105 lines (94 loc) · 4.7 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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, onInitial-scale=1.0">
<link rel="stylesheet" href="./css/style.css">
<link rel="stylesheet" href="./css/media-queries.css">
<title>Meme generator</title>
</head>
<body onload="onInit()">
<div class="main-container flex-col">
<!--HEADER-->
<header>
<div class="logo">
<h1><a href="index.html">Your MEME, such WOW</a></h1>
</div>
<input type="checkbox" class="openSidebarMenu" id="openSidebarMenu">
<label for="openSidebarMenu" class="sidebarIconToggle">
<div class="spinner diagonal part-1"></div>
<div class="spinner horizontal"></div>
<div class="spinner diagonal part-2"></div>
</label>
<div id="sidebarMenu">
<ul class="sidebarMenuInner">
<li><a href="#">About</a></li>
<li><a href="#" onclick="onToggleGallery('show')">Gallery</a></li>
<li><a href="#">Your Memes</a></li>
</ul>
</div>
</header>
<!--MAIN-->
<div class="gallery-wrapper">
<h4 class="gallery-headline">Choose your meme:</h4>
<div class="gallery-container gallery flex">Gallery</div>
</div>
<main class="main flex-col hidden">
<!--Controls-->
<div class="control-box">
<div class="text-inputs">
<input type="text" class="text-input" placeholder="Line 1: your text here..." onkeyup="onDrawText(this, 0)">
<button class="btn" onclick="onRemoveLine(0)">remove</button><br>
<input type="text" class="text-input" placeholder="Line 2: your text here..." onkeyup="onDrawText(this, 1)">
<button class="btn" onclick="onRemoveLine(1)">remove</button>
</div>
<!-- <button class="btn" onclick="onToggleLine()">Toggle</button> -->
<div class="move-line">
<button class="btn" onclick="onRowUp()">↑</button>
<button class="btn" onclick="onRowDown()">↓</button>
<button class="btn justify-R" onclick="onAlign('R')">align R</button>
<button class="btn justify-R" onclick="onAlign('C')">align C</button>
<button class="btn justify-L" onclick="onAlign('L')">align L</button>
</div>
<div class="color-inputs">
<label for="text-color">text color:</label>
<input type="color" class="text-color" onchange="onSetColor('fill')" value="#ffffff">
<label for="ouline-color">outline color:</label>
<input type="color" class="ouline-color" onchange="onSetColor('outline')">
</div>
<div class="size">
<button class="btn font-size" onclick="onIncreaseFont()">A+</button>
<button class="btn font-size" onclick="onDecreaseFont()">A-</button>
<select name="font-fam" onchange="onSetFont(this.value)">
<option value="font">Font</option>
<option value="Impact">Impact</option>
<option value="Arial">Arial</option>
<option value="Comic Sans MS">Comic</option>
</select>
<button onclick="clearCanvas()">Clear Canvas</button>
</div>
<!--Upload and share-->
<div class="inputs">
<input type="file" class="file-input" name="image" onchange="onImgInput(event)" />
<form action="" method="POST" enctype="multipart/form-data" onsubmit="uploadImg(this, event)">
<input name="img" id="imgData" type="hidden" />
<button class="btn" type="submit">Share</button>
<a href="#" class="btn" onclick="downloadImg(this)" download="my-img.jpg">Download masterpiece</a>
<div class="share-container"></div>
</form>
</div>
</div>
<!-- CANVAS -->
<div class="canvas-container" style="position: relative;">
<canvas id="my-canvas" height="250" width="250" style="outline:1px solid black; position: absolute;">
Sorry, your browser sucks and doesn't support canvas
</canvas>
</div>
</main>
</div>
<script src="js/meme-service.js"></script>
<script src="js/upload-service.js"></script>
<script src="js/meme-controller.js"></script>
</body>
</html>