Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set up tailwind #70

Merged
merged 1 commit into from
May 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
76 changes: 73 additions & 3 deletions app/views/home/index.erb
Original file line number Diff line number Diff line change
@@ -1,3 +1,73 @@
<h1 class="text-3xl font-bold underline">
Hello world!
</h1>
<div
class="min-h-screen flex items-center justify-center w-full dark:bg-gray-950"
>
<div
class="bg-white dark:bg-gray-900 shadow-md rounded-lg px-8 py-6 max-w-md"
>
<h1 class="text-2xl font-bold text-center mb-4 dark:text-gray-200">
Welcome Back!
</h1>
<form action="#">
<div class="mb-4">
<label
for="email"
class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2"
>Email Address</label
>
<input
type="email"
id="email"
class="shadow-sm rounded-md w-full px-3 py-2 border border-gray-300 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"
placeholder="[email protected]"
required
/>
</div>
<div class="mb-4">
<label
for="password"
class="block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2"
>Password</label
>
<input
type="password"
id="password"
class="shadow-sm rounded-md w-full px-3 py-2 border border-gray-300 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500"
placeholder="Enter your password"
required
/>
<a
href="#"
class="text-xs text-gray-600 hover:text-indigo-500 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
>Forgot Password?</a
>
</div>
<div class="flex items-center justify-between mb-4">
<div class="flex items-center">
<input
type="checkbox"
id="remember"
class="h-4 w-4 rounded border-gray-300 text-indigo-600 focus:ring-indigo-500 focus:outline-none"
checked
/>
<label
for="remember"
class="ml-2 block text-sm text-gray-700 dark:text-gray-300"
>Remember me</label
>
</div>
<a
href="#"
class="text-xs text-indigo-500 hover:text-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
>Create Account</a
>
</div>
<button
onclick="alert('hello')"
type="submit"
class="w-full flex justify-center py-2 px-4 border border-transparent rounded-md shadow-sm text-sm font-medium text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
>
Login
</button>
</form>
</div>
</div>
2 changes: 1 addition & 1 deletion app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

<body>
<main class="container mx-auto mt-28 px-5 flex">
<%= yield %>
<%=yield %>
</main>
</body>
</html>