From dfc3e184cbc7d21753a0acd747eec5a1cb4a8313 Mon Sep 17 00:00:00 2001
From: fran-ink <171171801+fran-ink@users.noreply.github.com>
Date: Fri, 7 Feb 2025 08:57:19 -0500
Subject: [PATCH] feat: make the side bar sticky by default
---
src/layout/InkLayout/InkLayout.stories.tsx | 21 +++++++++++++++++++++
src/layout/InkLayout/InkLayout.tsx | 17 +++++++++++++----
src/layout/InkParts/InkPageLayout.tsx | 2 +-
3 files changed, 35 insertions(+), 5 deletions(-)
diff --git a/src/layout/InkLayout/InkLayout.stories.tsx b/src/layout/InkLayout/InkLayout.stories.tsx
index 701ec51..b5efb38 100644
--- a/src/layout/InkLayout/InkLayout.stories.tsx
+++ b/src/layout/InkLayout/InkLayout.stories.tsx
@@ -78,3 +78,24 @@ export const SideNavWithCustomButtons: Story = {
),
},
};
+
+/**
+ * The side nav can be a custom component for routing, for instance, if you want to use NextJS' own {``} component.
+ */
+export const StickySideNav: Story = {
+ args: {
+ children: (
+
+
+
+
+ If the main content is bigger than the screen, the side nav will
+ be sticky.
+