Skip to content

Commit

Permalink
Merge pull request #189 from honeylogic-io/redisgn
Browse files Browse the repository at this point in the history
fix: Small design nits
  • Loading branch information
adinhodovic authored Jan 11, 2024
2 parents 5bdc801 + 3ff6cef commit d02584a
Show file tree
Hide file tree
Showing 10 changed files with 68 additions and 57 deletions.
6 changes: 3 additions & 3 deletions django_wtf/templates/core/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,18 @@
rel="stylesheet">
{% endblock head %}
</head>
<body class="flex flex-col w-screen lg:w-full content-center justify-start min-h-screen font-roboto">
<body class="font-roboto flex min-h-screen w-screen flex-col content-center justify-start lg:w-full">
{% include "core/components/_navbar.html" %}
{% if messages %}
<div class="mt-3 mx-auto">
<div class="mx-auto mt-3">
{% for message in messages %}
<div role="alert" class="alert alert-{{ message.tags }}">
<span>{{ message }}</span>
</div>
{% endfor %}
</div>
{% endif %}
<div class="flex flex-col content-center self-center mt-3 w-full lg:w-9/12">
<div class="flex w-full flex-col content-center self-center">
{% block content %}
{% endblock content %}
</div>
Expand Down
10 changes: 5 additions & 5 deletions django_wtf/templates/core/email_subscriber_landing.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
{% load static %}
load
{% block content %}
<img class="hidden lg:block object-cover w-8/12 mx-auto h-96 rounded-md"
<img class="mx-auto mt-10 hidden h-96 w-7/12 rounded-lg object-cover lg:block"
alt="django.wtf"
src="{% static 'images/django-wtf-dall-e-trending.png' %}">
<div class="hero">
<div class="w-full text-left hero-content">
<div class="hero mb-5 mt-5">
<div class="hero-content w-full text-left">
<div class="w-full lg:w-7/12">
<h1 class="text-3xl font-bold">Keep up with Django OSS</h1>
<p class="py-3">
Expand All @@ -21,7 +21,7 @@ <h1 class="text-3xl font-bold">Keep up with Django OSS</h1>
</p>
<p class="pb-1">
Every two weeks an email is sent out with:
<ul class="pb-3 font-bold list-disc list-inside">
<ul class="list-inside list-disc pb-3 font-bold">
<li>Top trending projects by growth %</li>
<li>Trending social media news</li>
<li>The engineers that maintain the most popular projects</li>
Expand All @@ -31,7 +31,7 @@ <h1 class="text-3xl font-bold">Keep up with Django OSS</h1>
I use it to
keep up on what's happening and so could you.
</p>
<div class="text-center py-4">
<div class="py-4 text-center">
{% if not request.user.is_authenticated %}
<a href="{% url "account_signup" %}?next={{ request.path }}"
class="btn btn-primary">Sign up</a>
Expand Down
50 changes: 25 additions & 25 deletions django_wtf/templates/core/index.html
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{% extends "core/base.html" %}
{% load user_agents %}
{% block content %}
<div class="lg:flex flex-col content-center self-center lg:mt-5 mb-5 w-full lg:w-11/12">
<div class="mt-5 mb-5 lg:rounded-lg bg-neutral">
<div class="mb-5 w-full flex-col content-center self-center lg:mt-5 lg:flex lg:w-7/12">
<div class="bg-neutral mb-5 mt-5 lg:rounded-lg">
<div class="p-6">
<h3 class="text-lg text-white">Categories</h3>
<div class="flex flex-wrap mt-3 gap-2">
<div class="mt-3 flex flex-wrap gap-2">
{% if request|is_mobile or request|is_tablet %}
{% for category in categories|slice:"6" %}
<a href="{% url 'core:category-detail' name=category.name %}"
class="btn btn-primary">
<span class="uppercase font-normal">{{ category.name }}
<span class="font-normal uppercase">{{ category.name }}
<span class="text-sm">({{ category.total_repositories }})</span>
</span>
</a>
Expand All @@ -19,7 +19,7 @@ <h3 class="text-lg text-white">Categories</h3>
{% for category in categories %}
<a href="{% url 'core:category-detail' name=category.name %}"
class="btn btn-primary">
<span class="uppercase font-normal">{{ category.name }}
<span class="font-normal uppercase">{{ category.name }}
<span class="text-sm">({{ category.total_repositories }})</span>
</span>
</a>
Expand All @@ -28,16 +28,16 @@ <h3 class="text-lg text-white">Categories</h3>
</div>
</div>
</div>
<div class="flex flex-col lg:flex-row gap-4">
<div class="p-4 lg:p-6 lg:rounded-lg lg:basis-1/2">
<div class="flex flex-col gap-4 lg:flex-row">
<div class="p-4 lg:basis-1/2 lg:rounded-lg lg:p-6">
<a href="{% url 'core:trending-repositories' %}"
class="hover:brightness-125">
<div class="pb-2 border-b-2 border-neutral-100">
<div class="border-b-2 border-neutral-100 pb-2">
<h3 class="text-lg font-bold">Trending Packages</h3>
</div>
</a>
<div class="overflow-x-auto mt-2">
<table class="table table-zebra w-full">
<div class="mt-2 overflow-x-auto">
<table class="table-zebra table w-full">
<tbody>
{% for repo in trending_apps %}
<tr>
Expand All @@ -57,11 +57,11 @@ <h3 class="text-lg font-bold">Trending Packages</h3>
</table>
</div>
</div>
<div class="p-4 lg:p-6 lg:rounded-lg lg:basis-1/2">
<div class="p-4 lg:basis-1/2 lg:rounded-lg lg:p-6">
<a href="{% url 'core:trending-profiles' %}"
class="hover:brightness-125">
<div class="pb-2 flex justify-between border-b-2 border-gray-100">
<h3 class="text-lg font-bold self-center">Trending Engineers</h3>
<div class="flex justify-between border-b-2 border-gray-100 pb-2">
<h3 class="self-center text-lg font-bold">Trending Engineers</h3>
<div class="avatar-group -space-x-6 justify-self-end">
{% if request|is_mobile or request|is_tablet %}
{% for profile in trending_developers|slice:":3" %}
Expand All @@ -81,15 +81,15 @@ <h3 class="text-lg font-bold self-center">Trending Engineers</h3>
{% endfor %}
{% endif %}
<div class="avatar placeholder">
<div class="w-7 bg-neutral-focus text-sm text-neutral-content">
<div class="bg-neutral-focus text-neutral-content w-7 text-sm">
<span>+99</span>
</div>
</div>
</div>
</div>
</a>
<div class="overflow-x-auto mt-2">
<table class="table table-zebra w-full">
<div class="mt-2 overflow-x-auto">
<table class="table-zebra table w-full">
<tbody>
{% for profile in trending_developers %}
<tr>
Expand All @@ -110,15 +110,15 @@ <h3 class="text-lg font-bold self-center">Trending Engineers</h3>
</div>
</div>
</div>
<div class="flex flex-col lg:flex-row gap-4 mt-4 mb-5">
<div class="p-4 lg:p-6 lg:rounded-lg lg:basis-1/2">
<div class="mb-5 mt-4 flex flex-col gap-4 lg:flex-row">
<div class="p-4 lg:basis-1/2 lg:rounded-lg lg:p-6">
<a href="{% url 'core:top-repositories' %}" class="hover:brightness-125">
<div class="pb-2 border-b-2 border-gray-100 ">
<div class="border-b-2 border-gray-100 pb-2 ">
<h3 class="text-lg font-bold">Top Packages</h3>
</div>
</a>
<div class="overflow-x-auto mt-2">
<table class="table table-zebra w-full">
<div class="mt-2 overflow-x-auto">
<table class="table-zebra table w-full">
<tbody>
{% for repo in top_apps %}
<tr>
Expand All @@ -138,15 +138,15 @@ <h3 class="text-lg font-bold">Top Packages</h3>
</table>
</div>
</div>
<div class="p-4 lg:p-6 lg:rounded-lg lg:basis-1/2">
<div class="p-4 lg:basis-1/2 lg:rounded-lg lg:p-6">
<a href="{% url 'core:social-media-news' %}"
class="hover:brightness-125">
<div class="pb-2 border-b-2 border-gray-100 ">
<div class="border-b-2 border-gray-100 pb-2 ">
<h3 class="text-lg font-bold">Social Media News</h3>
</div>
</a>
<div class="overflow-x-auto mt-2">
<table class="table table-zebra w-full">
<div class="mt-2 overflow-x-auto">
<table class="table-zebra table w-full">
<tbody>
{% for post in social_news %}
<tr>
Expand Down
8 changes: 4 additions & 4 deletions django_wtf/templates/core/social_media_news.html
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{% extends "core/base.html" %}
{% load user_agents %}
{% block content %}
<div class="flex flex-col self-center items-center p-4 lg:p-6 w-full lg:w-11/12">
<div class="flex flex-wrap self-start mt-3 mb-10 text-sm lg:text-lg gap-2">
<div class="flex w-full flex-col items-center self-center p-4 lg:w-7/12 lg:p-6">
<div class="mb-10 mt-3 flex flex-wrap gap-2 self-start text-sm lg:text-lg">
<div class="badge badge-lg badge-primary">Trending social media news</div>
</div>
<table class="table w-full leading-6 mb-5">
<table class="mb-5 table w-full leading-6">
<thead>
<tr>
<th class="hidden xl:block">Rank</th>
Expand Down Expand Up @@ -39,7 +39,7 @@
</span>
</a>
</td>
<td class="text-sm hidden xl:table-cell">
<td class="hidden text-sm xl:table-cell">
<a href="{{ url }}">{{ news.created_at }}</a>
</td>
<td>
Expand Down
12 changes: 6 additions & 6 deletions django_wtf/templates/core/top_profiles.html
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{% extends "core/base.html" %}
{% load user_agents %}
{% block content %}
<div class="flex flex-col self-center items-center p-4 lg:p-6 w-full lg:w-11/12">
<div class="flex flex-wrap self-start mt-3 mb-10 text-sm lg:text-lg gap-2">
<div class="flex w-full flex-col items-center self-center p-4 lg:w-7/12 lg:p-6">
<div class="mb-10 mt-3 flex flex-wrap gap-2 self-start text-sm lg:text-lg">
<div class="badge badge-lg badge-primary">Top contributors</div>
{% if request|is_mobile or request|is_tablet %}
<div class="badge badge-lg badge-primary">{{ page_obj.paginator.count }} prolific contributors</div>
{% else %}
<div class="badge badge-lg badge-primary">{{ page_obj.paginator.count }} prolific contributors to Django projects</div>
{% endif %}
</div>
<table class="table w-full leading-6 mb-5">
<table class="mb-5 table w-full leading-6">
<thead>
<tr>
<th class="hidden xl:block">Rank</th>
Expand All @@ -28,15 +28,15 @@
</td>
<td>
<a class="flex items-center" href="{{ url }}" target="_blank">
<img class="w-10 mr-2 rounded-full"
<img class="mr-2 w-10 rounded-full"
src="{{ profile.avatar_url }}"
alt="{{ profile.login }}">
{{ profile.login }}
</a>
</td>
<td class="text-sm hidden xl:table-cell">
<td class="hidden text-sm xl:table-cell">
{% for contribution in profile.top_contributions|slice:"0:2" %}
<a class="p-3 ml-2 badge badge-outline hover:brightness-125"
<a class="badge badge-outline ml-2 p-3 hover:brightness-125"
href="{{ contribution.repository.github_url }}"
target="_blank">
{{ contribution.repository.full_name|truncatechars:30 }}
Expand Down
6 changes: 3 additions & 3 deletions django_wtf/templates/core/top_repositories.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{% extends "core/base.html" %}
{% load user_agents %}
{% block content %}
<div class="flex flex-col self-center items-center p-4 lg:p-6 w-full lg:w-11/12">
<div class="flex flex-wrap self-start mt-3 mb-10 text-sm lg:text-lg gap-2">
<div class="flex w-full flex-col items-center self-center p-4 lg:w-7/12 lg:p-6">
<div class="mb-10 mt-3 flex flex-wrap gap-2 self-start text-sm lg:text-lg">
<div class="badge badge-lg badge-primary">Top repositories</div>
<div class="badge badge-lg badge-primary">Repositories with the most stars</div>
</div>
<table class="table w-full leading-6 mb-5">
<table class="mb-5 table w-full leading-6">
<thead>
<tr>
<th class="hidden xl:block">Rank</th>
Expand Down
12 changes: 6 additions & 6 deletions django_wtf/templates/core/trending_profiles.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@
{% load humanize %}
{% load user_agents %}
{% block content %}
<div class="flex flex-col self-center items-center p-4 lg:p-6 w-full lg:w-11/12">
<div class="flex flex-wrap self-start mt-3 mb-10 text-sm lg:text-lg gap-2">
<div class="flex w-full flex-col items-center self-center p-4 lg:w-7/12 lg:p-6">
<div class="mb-10 mt-3 flex flex-wrap gap-2 self-start text-sm lg:text-lg">
<div class="badge badge-lg badge-primary">Trending profiles</div>
{% if not request|is_mobile and not request|is_tablet %}
<div class="badge badge-lg badge-primary">
Engineers with the most new followers in the past {{ config.DAYS_SINCE_TRENDING | apnumber }} days
</div>
{% endif %}
</div>
<table class="table w-full mb-5">
<table class="mb-5 table w-full">
<thead>
<tr>
<th class="hidden xl:block">Rank</th>
Expand All @@ -33,15 +33,15 @@
</td>
<td>
<a class="flex items-center" href="{{ url }}">
<img class="w-10 mr-2 rounded-full"
<img class="mr-2 w-10 rounded-full"
alt="{{ profile.login }}"
src="{{ profile.avatar_url }}">
{{ profile.login }}
</a>
</td>
<td class="text-sm hidden xl:table-cell">
<td class="hidden text-sm xl:table-cell">
{% for contribution in profile.top_contributions|slice:"0:2" %}
<a class="p-3 ml-2 badge badge-outline hover:brightness-125"
<a class="badge badge-outline ml-2 p-3 hover:brightness-125"
href="{{ contribution.repository.github_url }}">
{{ contribution.repository.full_name|truncatechars:30 }}
<span class="ml-1">({{ contribution.contributions }})</span>
Expand Down
6 changes: 3 additions & 3 deletions django_wtf/templates/core/trending_repositories.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{% extends "core/base.html" %}
{% load humanize user_agents wtf_tags %}
{% block content %}
<div class="flex flex-col items-center self-center w-full p-4 lg:p-6 lg:w-11/12">
<div class="flex flex-wrap self-start mt-3 mb-10 text-sm lg:text-lg gap-2">
<div class="flex w-full flex-col items-center self-center p-4 lg:w-7/12 lg:p-6">
<div class="mb-10 mt-3 flex flex-wrap gap-2 self-start text-sm lg:text-lg">
<div class="badge badge-lg badge-primary">Trending repositories</div>
{% if request|is_mobile or request|is_tablet %}
<div class="badge badge-lg badge-primary">Repositories with the most stars</div>
Expand All @@ -13,7 +13,7 @@
</div>
{% endif %}
</div>
<table class="table w-full mb-5 leading-6">
<table class="mb-5 table w-full leading-6">
<thead>
<tr>
<th class="hidden xl:block">Rank</th>
Expand Down
13 changes: 12 additions & 1 deletion django_wtf/templates/wagtail_code_blog/blog_index_page.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,19 @@
{% include "wagtail_code_blog/blog_index_page_head.html" %}
{{ block.super }}
{{ tailwind_css }}
<style>
h3,
h4,
p {
color: black;
}

.intro-info>small {
color: white !important;
}
</style>
{% endblock head %}
{% block content %}
{{ block.super }}
<div class="mb-20">{% include "wagtail_code_blog/blog_index_page_body.html" %}</div>
<div class="w-full bg-white pb-10 pt-10">{% include "wagtail_code_blog/blog_index_page_body.html" %}</div>
{% endblock content %}
2 changes: 1 addition & 1 deletion django_wtf/templates/wagtail_code_blog/blog_page.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
{{ tailwind_css }}
{% endblock head %}
{% block content %}
<div class="-mt-3 flex justify-center bg-slate-500 pb-5 pb-5 md:pb-7 md:pt-7">
<div class="flex w-11/12 justify-center bg-white pb-5 pb-5 md:pb-7 md:pt-7 lg:w-full">
{% include "wagtail_code_blog/blog_page_body.html" %}
</div>
{% endblock content %}

0 comments on commit d02584a

Please sign in to comment.