fixing some layout stuff on the sections

This commit is contained in:
Chris Cochrun 2025-06-25 11:16:30 -05:00
parent cc089e8cdc
commit e0b4c55364
28 changed files with 42 additions and 5 deletions

View file

@ -1537,11 +1537,26 @@
width: calc(1/3 * 100%); width: calc(1/3 * 100%);
} }
} }
.md\:w-full {
@media (width >= 48rem) {
width: 100%;
}
}
.md\:max-w-md { .md\:max-w-md {
@media (width >= 48rem) { @media (width >= 48rem) {
max-width: var(--container-md); max-width: var(--container-md);
} }
} }
.md\:flex-1 {
@media (width >= 48rem) {
flex: 1;
}
}
.md\:flex-2 {
@media (width >= 48rem) {
flex: 2;
}
}
.md\:basis-1\/4 { .md\:basis-1\/4 {
@media (width >= 48rem) { @media (width >= 48rem) {
flex-basis: calc(1/4 * 100%); flex-basis: calc(1/4 * 100%);
@ -1552,6 +1567,11 @@
flex-basis: calc(3/4 * 100%); flex-basis: calc(3/4 * 100%);
} }
} }
.md\:basis-full {
@media (width >= 48rem) {
flex-basis: 100%;
}
}
.md\:grid-cols-2 { .md\:grid-cols-2 {
@media (width >= 48rem) { @media (width >= 48rem) {
grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-columns: repeat(2, minmax(0, 1fr));
@ -1562,6 +1582,20 @@
flex-direction: row; flex-direction: row;
} }
} }
.md\:space-x-4 {
@media (width >= 48rem) {
:where(& > :not(:last-child)) {
--tw-space-x-reverse: 0;
margin-inline-start: calc(calc(var(--spacing) * 4) * var(--tw-space-x-reverse));
margin-inline-end: calc(calc(var(--spacing) * 4) * calc(1 - var(--tw-space-x-reverse)));
}
}
}
.md\:px-0 {
@media (width >= 48rem) {
padding-inline: calc(var(--spacing) * 0);
}
}
.lg\:block { .lg\:block {
@media (width >= 64rem) { @media (width >= 64rem) {
display: block; display: block;

2
static/js/zoom.js Normal file

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 138 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 169 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 110 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 101 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 54 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 138 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 69 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

View file

@ -1,6 +1,7 @@
{% extends "layout.html" %} {% extends "layout.html" %}
{% block content %} {% block content %}
<script src="/js/zoom.js"/>
<div class="flex px-4"> <div class="flex px-4">
<h1 class="text-2xl text-bold my-6 mx-auto"> <h1 class="text-2xl text-bold my-6 mx-auto">
{{ page.title }} {{ page.title }}

View file

@ -32,23 +32,23 @@
{% set image = page.path ~ page.extra.image %} {% set image = page.path ~ page.extra.image %}
{% endif %} {% endif %}
{% if image %} {% if image %}
{% set resized = resize_image(path="/content" ~ image, width=200, height=200, op="fit_height") %} {% set resized = resize_image(path="/content" ~ image, width=500, height=500, op="fit_height") %}
{% else %} {% else %}
{% set resized = "" %} {% set resized = "" %}
{% endif %} {% endif %}
<div class="flex flex-wrap space-x-4 border border-2 border-gray-200 dark:border-black rounded-xl shadow-xl hover:shadow-xl/30 transform transition duration-500 hover:scale-105 bg-gray-200 dark:bg-gray-800 place-content-center cursor-pointer" onclick='location.href="{{ page.permalink }}";'> <div class="flex flex-wrap md:space-x-4 border border-2 border-gray-200 dark:border-black rounded-xl shadow-xl hover:shadow-xl/30 transform transition duration-500 hover:scale-105 bg-gray-200 dark:bg-gray-800 place-content-center cursor-pointer" onclick='location.href="{{ page.permalink }}";'>
<!-- Image --> <!-- Image -->
{% if resized %} {% if resized %}
<div class="w-full md:w-1/3 flex-2 rounded-lg place-content-center"> <div class="w-full basis-full md:flex-2 rounded-lg place-content-center">
<img class="object-cover object-top w-full h-96 lg:h-72 md:h-72 nozoom rounded-lg" src="{{ resized.url }}"/> <img class="object-cover object-top md:w-full w-full h-96 lg:h-72 md:h-72 nozoom rounded-lg" src="{{ resized.url }}"/>
</div> </div>
{% else %} {% else %}
<div class="ml-5"> <div class="ml-5">
</div> </div>
{% endif %} {% endif %}
<div class="flex flex-col flex-3 mr-5"> <div class="flex flex-col flex-3 mr-5 px-4 md:px-0">
<h2 class="text-2xl text-bold"><a href='{{ page.permalink }}'>{{ page.title }}</a></h2> <h2 class="text-2xl text-bold"><a href='{{ page.permalink }}'>{{ page.title }}</a></h2>
<p class="text-bold text-ellipsis">{{ page.description | linebreaksbr | safe }}</p> <p class="text-bold text-ellipsis">{{ page.description | linebreaksbr | safe }}</p>