Skip to content

Commit

Permalink
fix: improve mobile view
Browse files Browse the repository at this point in the history
  • Loading branch information
luizchaves committed Oct 20, 2024
1 parent ffb166d commit 43a47de
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/components/NavBar.astro
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import ThemeToggle from './ThemeToggle';
<section class="px-4 py-2">
<nav class="flex items-center justify-between">
<a class="text-lg font-bold font-heading" href="/dw/">
<span class="md:hidden">DW</span>
<span class="sm:hidden">Desen. Web</span>
<span class="max-sm:hidden">Desenvolvimento Web</span>
</a>

Expand Down
2 changes: 1 addition & 1 deletion src/components/Sidebar.astro
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { MENU } from '../consts';

<aside
id="default-sidebar"
class="fixed z-50 left-0 top-11 md:h-screen md:w-36 xl:w-48 self-start bg-gray-100 dark:bg-slate-800 hidden lg:block"
class="fixed z-50 left-0 top-11 md:h-screen w-full md:w-64 self-start shadow-md bg-gray-100 dark:bg-slate-800 hidden dark:border-r-white/30 dark:border-r lg:block"
aria-label="Sidebar"
>
<div class="md:h-screen px-3 py-4 overflow-y-auto">
Expand Down
2 changes: 1 addition & 1 deletion src/components/TableOfContent.astro
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const { headings } = Astro.props;
---

<nav
class="toc fixed top-11 right-0 h-[calc(100vh-2.75rem)] py-8 px-2 lg:w-56 xl:w-64 self-start hidden lg:block overflow-y-scroll"
class="toc fixed top-11 right-0 h-[calc(100vh-2.75rem)] py-8 lg:w-56 xl:w-64 self-start hidden xl:block overflow-y-scroll"
>
<ul class="flex flex-col gap-2">
{
Expand Down
2 changes: 1 addition & 1 deletion src/layouts/BaseLayout.astro
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const { pageTitle } = Astro.props;
>
<Sidebar />

<article class="mx-auto py-8 lg:pl-40 xl:pl-64 max-sm:px-4">
<article class="mx-auto lg:ml-64 py-8 px-4 md:w-full">
<slot />
</article>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/layouts/MarkDownLayout.astro
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ const githubEditUrl = `${GITHUB_EDIT_URL}/src${file.split('/src').pop()}`;
<Sidebar />

<article
class="basis-full prose 2xl:prose-xl mx-auto py-8 max-sm:px-4 xl:px-4 xl:max-w-screen-md dark:prose-invert overflow-hidden"
class="mx-auto lg:max-xl:ml-64 py-8 px-4 md:px-6 max-xl:max-w-none w-full prose 2xl:prose-xl dark:prose-invert overflow-hidden"
>
<slot />

Expand Down
4 changes: 2 additions & 2 deletions src/pages/classnotes.astro
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ classroomEntries.sort(
---

<BaseLayout pageTitle="Conteúdos">
<main class="mx-auto">
<main>
<h1 class="font-bold text-4xl text-center pb-16 pt-24">Conteúdos</h1>
<div
class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4 pb-16 px-4"
class="max-w-7xl mx-auto grid grid-cols-1 md:grid-cols-2 xl:grid-cols-3 gap-4 pb-16 px-4"
>
{
classroomEntries.map((entry) => (
Expand Down

0 comments on commit 43a47de

Please sign in to comment.