Skip to content

Commit

Permalink
Reuse heading templex
Browse files Browse the repository at this point in the history
  • Loading branch information
tbrlpld committed Oct 3, 2023
1 parent 7837cbc commit 59ee200
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 4 additions & 0 deletions lpld/home/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ def get_context(self, request):
"title": heading.Heading(level=1, text=self.title),
"introduction": self.introduction,
"profile_image": self.profile_image,
"projects_heading": heading.Heading(
level=2,
text="These are things I have build before",
),
"projects": self.get_projects_teaser_grid(),
}

Expand Down
3 changes: 1 addition & 2 deletions lpld/templates/pages/home/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
{% block content %}
<section class="mt-44">
<div class="wrapper flex justify-between items-center">
{% #heading level="1" extra_class="inline-block" %}{{ page.title }}{% /heading %}
{% templex title extra_class="inline-block" %}

<div class="relative w-24 sm:w-32 md:w-48 lg:w-64 aspect-square rounded-full overflow-hidden bg-neutral-200 isolate">
Expand Down Expand Up @@ -43,7 +42,7 @@
</section>

<section id="projects" class="mt-16 lg:mt-32 pt-16 lg:mt-32">
{% #heading level="2" size="md" extra_class="max-w-lg lg:max-w-2xl" %}These are things I have built before{% /heading %}
{% templex projects_heading size="md" extra_class="max-w-lg lg:max-w-2xl" %}
{% templex projects %}
</section>
{% endblock content %}

0 comments on commit 59ee200

Please sign in to comment.