From 75eca0029d6a25ee1e31bfbb2e74657d663b30d0 Mon Sep 17 00:00:00 2001 From: Damian Stasik <920747+damianstasik@users.noreply.github.com> Date: Mon, 18 Sep 2023 14:59:54 +0200 Subject: [PATCH 1/5] Make docs a bit easier on the eyes --- src/theme/DocItem/Content.tsx | 46 ++++++++++++++++++++++++++++++++++- 1 file changed, 45 insertions(+), 1 deletion(-) diff --git a/src/theme/DocItem/Content.tsx b/src/theme/DocItem/Content.tsx index ed36939c..6ba05e97 100644 --- a/src/theme/DocItem/Content.tsx +++ b/src/theme/DocItem/Content.tsx @@ -1,9 +1,53 @@ import React from "react"; +import clsx from "clsx"; import MDXContent from "@theme/MDXContent"; +const classNames = [ + "prose", + "lg:prose-lg", + "text-gray-800", + "dark:text-gray-200", + "dark:prose-invert", + "marker:text-gray-600", + "dark:marker:text-gray-400", + "max-w-none", + + //
+ "prose-hr:my-6", + "prose-hr:border-gray-200", + "prose-hr:border-solid", + "dark:prose-hr:border-gray-800", + + //
+  "prose-pre:bg-blue-900",
+
+  // 
+  "prose-code:px-1.5",
+  "prose-code:text-gray-800",
+  "dark:prose-code:text-gray-200",
+  "dark:prose-code:border-gray-600",
+  "prose-code:before:content-none",
+  "prose-code:after:content-none",
+
+  // 
+  "prose-a:text-gray-800",
+  "hover:prose-a:text-black",
+  "dark:prose-a:text-gray-200",
+  "dark:hover:prose-a:text-white",
+
+  // 
+  "prose-strong:text-gray-800",
+  "dark:prose-strong:text-gray-200",
+
+  // 

,

,

+ "prose-h1:text-4xl", + "prose-h2:text-3xl", + "prose-h3:text-2xl", +]; + export default function DocItemContent({ children }) { return ( -
+
{children}
); From 095794baa3caaad42f6841ccb94946e86135e45a Mon Sep 17 00:00:00 2001 From: Damian Stasik <920747+damianstasik@users.noreply.github.com> Date: Mon, 18 Sep 2023 15:03:22 +0200 Subject: [PATCH 2/5] Simplify and increase the contrast even more --- src/theme/DocItem/Content.tsx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/theme/DocItem/Content.tsx b/src/theme/DocItem/Content.tsx index 6ba05e97..e6cc1363 100644 --- a/src/theme/DocItem/Content.tsx +++ b/src/theme/DocItem/Content.tsx @@ -5,8 +5,8 @@ import MDXContent from "@theme/MDXContent"; const classNames = [ "prose", "lg:prose-lg", - "text-gray-800", - "dark:text-gray-200", + "text-gray-900", + "dark:text-gray-50", "dark:prose-invert", "marker:text-gray-600", "dark:marker:text-gray-400", @@ -23,21 +23,21 @@ const classNames = [ // "prose-code:px-1.5", - "prose-code:text-gray-800", - "dark:prose-code:text-gray-200", + "prose-code:text-current", + "dark:prose-code:text-current", "dark:prose-code:border-gray-600", "prose-code:before:content-none", "prose-code:after:content-none", //
- "prose-a:text-gray-800", + "prose-a:text-current", "hover:prose-a:text-black", - "dark:prose-a:text-gray-200", + "dark:prose-a:text-current", "dark:hover:prose-a:text-white", // - "prose-strong:text-gray-800", - "dark:prose-strong:text-gray-200", + "prose-strong:text-current", + "dark:prose-strong:text-current", //

,

,

"prose-h1:text-4xl", From e074be1f0b41aabb35dde3aed45d395c428a36a9 Mon Sep 17 00:00:00 2001 From: Damian Stasik <920747+damianstasik@users.noreply.github.com> Date: Mon, 18 Sep 2023 15:05:23 +0200 Subject: [PATCH 3/5] Make link hover more noticable --- src/theme/DocItem/Content.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/theme/DocItem/Content.tsx b/src/theme/DocItem/Content.tsx index e6cc1363..a212cf44 100644 --- a/src/theme/DocItem/Content.tsx +++ b/src/theme/DocItem/Content.tsx @@ -31,9 +31,9 @@ const classNames = [ // "prose-a:text-current", - "hover:prose-a:text-black", + "hover:prose-a:text-black/50", "dark:prose-a:text-current", - "dark:hover:prose-a:text-white", + "dark:hover:prose-a:text-white/50", // "prose-strong:text-current", From bba9b9cbf50971da42e8604c3494132fe696ad7b Mon Sep 17 00:00:00 2001 From: Damian Stasik <920747+damianstasik@users.noreply.github.com> Date: Mon, 18 Sep 2023 15:13:46 +0200 Subject: [PATCH 4/5] Bring down the text color in dark mode --- src/theme/DocItem/Content.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/theme/DocItem/Content.tsx b/src/theme/DocItem/Content.tsx index a212cf44..2b902d5b 100644 --- a/src/theme/DocItem/Content.tsx +++ b/src/theme/DocItem/Content.tsx @@ -6,7 +6,7 @@ const classNames = [ "prose", "lg:prose-lg", "text-gray-900", - "dark:text-gray-50", + "dark:text-gray-100", "dark:prose-invert", "marker:text-gray-600", "dark:marker:text-gray-400", From f4e8301f179655c6cf579a5edf32fe79362e587b Mon Sep 17 00:00:00 2001 From: Damian Stasik <920747+damianstasik@users.noreply.github.com> Date: Mon, 18 Sep 2023 15:35:32 +0200 Subject: [PATCH 5/5] Fix table padding --- src/theme/DocItem/Content.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/theme/DocItem/Content.tsx b/src/theme/DocItem/Content.tsx index 2b902d5b..534f8362 100644 --- a/src/theme/DocItem/Content.tsx +++ b/src/theme/DocItem/Content.tsx @@ -43,6 +43,9 @@ const classNames = [ "prose-h1:text-4xl", "prose-h2:text-3xl", "prose-h3:text-2xl", + + "prose-th:px-3", + "prose-td:px-3", ]; export default function DocItemContent({ children }) {