-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathpenguin.html
More file actions
114 lines (99 loc) · 4.78 KB
/
penguin.html
File metadata and controls
114 lines (99 loc) · 4.78 KB
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
106
107
108
109
110
111
112
113
114
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Icon -->
<link rel="icon" href="favicon.ico">
<!-- Title -->
<title>Penguin Classics Cover Generator</title>
<!-- Import JQUERY -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<!-- Import Materialize stylesheet -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.99.0/css/materialize.min.css">
<!-- Import Materialize JS -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.99.0/js/materialize.min.js"></script>
<!-- Import main stylesheet -->
<link rel="stylesheet" type="text/css" href="css/style.css"></link>
</head>
<body>
<!-- Pre-load fonts -->
<div style="font-family: GillSansMT;"></div>
<div style="font-family: BemboStd;"></div>
<!-- Body -->
<div class="container">
<div class="row">
<div class="col s6">
<!-- CONTROLS -->
<div id="controls">
<!-- FILE UPLOAD -->
<div class="card-panel white">
<div class="file-field input-field">
<form>
<div class="waves-effect waves-light btn blue-grey darken-4">
<span>File</span>
<input type="file" id="file_input">
</div>
<div class="file-path-wrapper">
<input class="file-path validate" type="text" placeholder="Upload image file">
</div>
</div>
</form>
</div>
</div>
<!-- END FILE UPLOAD -->
<div class="card-panel white">
Width: <input type="range" class="range-field" oninput="scale_image(photo_canvas, photo_ctx)" id="width_range" value="50">
<br />
Height: <input type="range" class="range-field" oninput="scale_image(photo_canvas, photo_ctx)" id="height_range" value="50">
<br />
X: <input type="range" class="range-field" oninput="translate_image(photo_canvas, photo_ctx)" id="x_range" min="-500" max="500" value="0">
<br />
Y: <input type="range" class="range-field" oninput="translate_image(photo_canvas, photo_ctx)" id="y_range" min="-500" max="500" value="0">
</div>
<ul class="collapsible" data-collapsible="accordion">
<!-- PENGUIN -->
<li>
<div class="collapsible-header" id="header-penguin" onclick="switch_brand('penguin');">
Penguin
</div>
<div class="collapsible-body">
<input type="text" id="penguin_author" placeholder="Author"></input>
<input type="text" id="penguin_title" placeholder="Title"></input>
<p>Pick an author color</p>
<a class="waves-effect waves-light btn" style="background-color: #C6422C" onclick="change_author_color('#C6422C')">RED</a>
<a class="waves-effect waves-light btn" style="background-color: #D28928" onclick="change_author_color('#D28928')">YELLOW</a>
</div>
</li>
<!-- OXFORD -->
<li>
<div class="collapsible-header" id="header-oxford" onclick="switch_brand('oxford');">
Oxford World Classics
</div>
<div class="collapsible-body">
<input type="text" id="oxford_author" placeholder="Author"></input>
<input type="text" id="oxford_title" placeholder="Title"></input>
</div>
</li>
</ul>
</div>
<!-- END CONTROLS -->
<div class="col s6">
<div id="canvas-wrapper">
<canvas id="photo_canvas" width="500" height="775"></canvas>
<canvas id="bg_canvas" width="500" height="775"></canvas>
<canvas id="canvas" width="500" height="775"></canvas>
<canvas id="dl_canvas" width="500" height="775"></canvas>
</div>
</div>
</div>
<!-- Footer -->
<div class="row">
<button class="waves-effect waves-light btn-large blue-grey darken-4" onclick="download_canvas(bg_canvas, photo_canvas, canvas)">Download</button>
</div>
<!-- Import main JS script -->
<script src="js/main.js" type="text/javascript"></script>
</body>
</html>
<!-- Google Analytics -->
<script>
!function(e,t,a,n,c,o,s){e.GoogleAnalyticsObject=c,e[c]=e[c]||function(){(e[c].q=e[c].q||[]).push(arguments)},e[c].l=1*new Date,o=t.createElement(a),s=t.getElementsByTagName(a)[0],o.async=1,o.src="https://www.google-analytics.com/analytics.js",s.parentNode.insertBefore(o,s)}(window,document,"script",0,"ga"),ga("create","UA-102565435-1","auto"),ga("send","pageview");
</script>