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

Fix mobile styling #36

Merged
merged 2 commits into from
Jul 20, 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
2 changes: 1 addition & 1 deletion app/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class Meta:
widgets = {
"query": forms.TextInput(
attrs={
"class": "w-1/2 border-0 rounded-full p-2 pl-3 pl-r ring-1 ring-inset ring-gray-500 focus:ring-purple-500 hover:ring-purple-500 placeholder:text-gray-400 focus:ring-2 focus:ring-inset",
"class": "sm:w-1/2 w-full border-0 rounded-full p-2 pl-3 pl-r ring-1 ring-inset ring-gray-500 focus:ring-purple-500 hover:ring-purple-500 placeholder:text-gray-400 focus:ring-2 focus:ring-inset",
"required": "true",
"placeholder": "Search...",
}
Expand Down
10 changes: 8 additions & 2 deletions app/templates/app/components/footer.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
<footer class="flex justify-center py-4">
<p class="text-xs text-gray-500">
<footer class="flex justify-center pb-4 pt-8 space-x-4 text-xs text-gray-500">
<p>
GitHub:
<a class="text-purple-500 underline"
href="https://github.com/aurora-dot">aurora-dot</a>
</p>
<p>/</p>
<p>
Source:
<a class="text-purple-500 underline"
href="https://github.com/aurora-dot/NotifyTube">NotifyTube</a>
</p>
</footer>
36 changes: 19 additions & 17 deletions app/templates/app/query.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,30 +9,32 @@
<p class="py-4 text-center text-xl text-green-600">Success!</p>
{% else %}
<div class="flex justify-center pt-8 pb-16">
<div class="flex flex-col py-12 ring-1 ring-gray-200 rounded-md shadow-lg w-10/12 justify-center">
<p class="text-center text-gray-600 font-semibold mb-3">Subscribe to email notifications</p>
<div class="flex flex-col sm:py-12 py-8 ring-1 ring-gray-200 rounded-md shadow-lg w-10/12 justify-center">
<p class="text-center text-gray-600 font-semibold sm:mb-3 mb-8">Subscribe to email notifications</p>
<form action="{% url "app:query" object_list.0.youtube_query.query %}"
method="post"
class="justify-center flex flex-row space-x-6 text-sm">
class="justify-center flex sm:flex-row flex-col sm:space-x-6 sm:space-y-0 space-y-6 sm:px-3 px-3 text-sm">
{% for field in email_form %}
{% csrf_token %}
<div class="flex {% if forloop.last %}w-1/2{% endif %} flex-row items-center">
<div class="flex ml-0 {% if forloop.last %}sm:w-1/2{% endif %} flex-row items-center">
<label class="pr-4" for="{{ field.auto_id }}">{{ field.label }}:</label>
{{ field }}
</div>
{% endfor %}
<button type="submit"
class="rounded-full p-2 ring-1 ring-inset ring-gray-400 hover:ring-purple-500 active:ring-2"
aria-label="submit">
<svg xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
class="size-5 text-gray-500">
<path stroke-linecap="round" stroke-linejoin="round" d="M6 12 3.269 3.125A59.769 59.769 0 0 1 21.485 12 59.768 59.768 0 0 1 3.27 20.875L5.999 12Zm0 0h7.5" />
</svg>
</button>
<div class="flex items-center justify-center">
<button type="submit"
class="rounded-full p-2 ring-1 ring-inset ring-gray-400 hover:ring-purple-500 active:ring-2"
aria-label="submit">
<svg xmlns="http://www.w3.org/2000/svg"
fill="none"
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
class="size-5 text-gray-500">
<path stroke-linecap="round" stroke-linejoin="round" d="M6 12 3.269 3.125A59.769 59.769 0 0 1 21.485 12 59.768 59.768 0 0 1 3.27 20.875L5.999 12Zm0 0h7.5" />
</svg>
</button>
</div>
{% csrf_token %}
</form>
</div>
</div>
Expand Down
Loading