-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
156 lines (144 loc) · 5.24 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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
<!DOCTYPE html>
<html lang="en-Us">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<title>QR Code Generator</title>
<link rel="icon" type="image/jpg" href="./assets/qrPng.jpg" />
<meta name="description" content="QR code generator" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet" href="./dist/output.css" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.2/css/all.min.css"
integrity="sha512-z3gLpd7yknf1YoNbCzqRKc4qyor8gaKU1qmn+CShxbuBusANI9QpRohGBreCFkKxLhei6S9CQXFEbbKuqLg0DA=="
crossorigin="anonymous"
referrerpolicy="no-referrer"
/>
</head>
<body>
<header
class="h-[80px] flex items-center justify-center fixed top-0 right-0 z-10 w-[100vw] px-[20px]"
>
<h2 class="text-white lg:text-3xl text-[24px] font-bold text-center">
QUICK RESPONSE CODE GENERATOR
</h2>
</header>
<div id="wrapper" class="flex justify-around items-center mt-[90px]">
<section class="md:w-[40%] w-full px-[20px]">
<h1 class="font-extrabold lg:text-2xl mb-3">QR CODE GENERATOR</h1>
<p>
QR Codes are easier to use for navigating websites with mobile phones.
Generate your QR Code below for seamless experience.
</p>
<form id="submit" class="mt-3">
<input
type="url"
title="Must include 'https://' "
name="url"
id="url"
placeholder="Enter URL"
class="border w-full h-[40px] px-2 rounded-[8px] outline-[1px] outline-purple-700 mb-3"
required
/>
<div class="relative">
<input
id="size-input"
class="w-full h-[40px] rounded-[8px] border-[#E5E7EB] border-[1px] px-2 outline-purple-700 mb-1"
required
placeholder="Choose size"
value="100 X 100"
readonly
title="size"
data-size="100"
/>
<i
id="dropdownIcon"
class="fa-solid fa-caret-down absolute right-[12px] top-[12px] cursor-pointer"
></i>
<div
id="sizes"
class="h-auto w-[100%] border-[1px] border-[#E5E7EB] bg-white shadow-lg rounded-[8px] absolute z-10 hidden"
>
<div
id="size1"
class="w-full h-[40px] hover:bg-purple-700 rounded-[8px] hover:text-white px-2 flex items-center cursor-pointer"
>
<p>100 X 100</p>
</div>
<div
id="size2"
class="w-full h-[40px] hover:bg-purple-700 rounded-[8px] hover:text-white px-2 flex items-center cursor-pointer"
>
<p>200 X 200</p>
</div>
<div
id="size3"
class="w-full h-[40px] hover:bg-purple-700 rounded-[8px] hover:text-white px-2 flex items-center cursor-pointer"
>
<p>300 X 300</p>
</div>
<div
id="size4"
class="w-full h-[40px] hover:bg-purple-700 rounded-[8px] hover:text-white px-2 flex items-center cursor-pointer"
>
<p>400 X 400</p>
</div>
</div>
</div>
<!-- <select
title="size"
class="border w-full h-[40px] px-2 cursor-pointer rounded-[8px] outline-[1px] outline-purple-700"
id="size"
>
<option value="100" selected>100 X 100</option>
<option value="200">200 X 200</option>
<option value="300">300 X 300</option>
<option value="400" class="md:block hidden">400 X 400</option>
</select> -->
<button
type="submit"
id="btn"
class="hover:scale-[1.02] duration-500 transition mt-4 text-white h-[40px] rounded-[8px] w-full"
>
Generate Code
</button>
</form>
</section>
<section id="dummy-image" class="md:block hidden">
<img
src="./assets/qr.jpg"
alt="dummy-QR-Code"
class="w-[350px] h-[350px] lg:w-full md:h-full"
id="image1"
/>
</section>
</div>
<div id="made" class="mt-4 md:mt-0">
<div id="spin" class="">
<img
src="./assets/spinner.svg"
alt="Loading..."
id="spinner"
class="w-24 mx-auto hidden"
/>
</div>
<div
id="generated-code"
class="mb-2 flex items-center justify-center"
></div>
<div
id="download"
class="mt-4 mb-2 flex items-center justify-center hover:opacity-70 transition text-white rounded-[8px]"
></div>
</div>
<script src="script.js"></script>
<!-- CODE GENERATOR LIBRARY (qrcode.js) SCRIPT GOTTEN FROM (cdnjs.com) -->
<script
src="https://cdnjs.cloudflare.com/ajax/libs/qrcodejs/1.0.0/qrcode.min.js"
integrity="sha512-CNgIRecGo7nphbeZ04Sc13ka07paqdeTu0WR1IM4kNcpmBAUSHSQX0FslNhTDadL4O5SAGapGt4FodqL8My0mA=="
crossorigin="anonymous"
referrerpolicy="no-referrer"
></script>
</body>
</html>