File size: 3,029 Bytes
131b4ff
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Password Protected Note</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <script>

        tailwind.config = {

            theme: {

                extend: {

                    spacing: {

                        '18': '4.5rem',

                    },

                }

            }

        }

    </script>
</head>
<body class="bg-white min-h-screen">
    <div class="container mx-auto px-4 py-8 sm:py-12">
        <div class="max-w-md mx-auto bg-white rounded-lg shadow-sm border border-gray-200 p-5 sm:p-8">
            <h1 class="text-2xl font-bold text-center text-black mb-4">Password Protected Note</h1>
            <p class="text-gray-700 mb-6 text-center text-sm sm:text-base">This note is private and requires a password to view</p>
            
            {% if error %}
            <div class="bg-gray-100 border-l-4 border-black text-gray-800 px-4 py-3 rounded mb-6" role="alert">
                <p class="font-medium">{{ error }}</p>
            </div>
            {% endif %}
            
            <form action="/{{ code }}/verify" method="post" class="space-y-6">
                <div>
                    <label for="password" class="block text-sm font-medium text-black mb-2">Password</label>
                    <input 

                        type="password" 

                        id="password" 

                        name="password" 

                        class="w-full px-4 py-3 border border-gray-300 rounded-lg shadow-sm focus:outline-none focus:ring-black focus:border-black text-base"

                        placeholder="Enter the note password"

                        required

                    >
                </div>
                
                <div>
                    <button 

                        type="submit" 

                        class="w-full flex justify-center py-3 px-4 border border-gray-800 rounded-lg shadow-sm text-base font-medium text-white bg-black hover:bg-gray-800 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-gray-500 transition-colors duration-200"

                    >
                        Access Note
                    </button>
                </div>
            </form>
            
            <div class="mt-8 text-center">
                <a href="/" class="inline-flex items-center justify-center text-black hover:text-gray-700 font-medium transition-colors duration-200">
                    <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4 mr-2" fill="none" viewBox="0 0 24 24" stroke="currentColor">
                        <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M10 19l-7-7m0 0l7-7m-7 7h18" />
                    </svg>
                    Back to Notepad
                </a>
            </div>
        </div>
    </div>
</body>
</html>