From 6279fd02c6d721ac596188255d0dd23cab13b9f8 Mon Sep 17 00:00:00 2001 From: Damian Stasik <920747+damianstasik@users.noreply.github.com> Date: Tue, 19 Sep 2023 13:31:35 +0200 Subject: [PATCH] Remove logos (#121) --- docusaurus.config.js | 18 ------------------ src/components/Supporters/index.tsx | 7 +++---- src/components/SupportersList/index.tsx | 21 ++------------------- static/logos/env0-light.svg | 1 - static/logos/env0.svg | 1 - static/logos/gruntwork-light.svg | 14 -------------- static/logos/gruntwork.png | Bin 5267 -> 0 bytes static/logos/harness-light.png | Bin 11493 -> 0 bytes static/logos/harness.svg | 4 ---- static/logos/scalr-light.png | Bin 8211 -> 0 bytes static/logos/scalr.svg | 1 - static/logos/spacelift-light.svg | 1 - static/logos/spacelift.svg | 3 --- 13 files changed, 5 insertions(+), 66 deletions(-) delete mode 100644 static/logos/env0-light.svg delete mode 100644 static/logos/env0.svg delete mode 100644 static/logos/gruntwork-light.svg delete mode 100644 static/logos/gruntwork.png delete mode 100644 static/logos/harness-light.png delete mode 100644 static/logos/harness.svg delete mode 100644 static/logos/scalr-light.png delete mode 100644 static/logos/scalr.svg delete mode 100644 static/logos/spacelift-light.svg delete mode 100644 static/logos/spacelift.svg diff --git a/docusaurus.config.js b/docusaurus.config.js index bd39510e..c0ed9b8b 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -250,24 +250,6 @@ const config = { }, image: "/img/og.png", }), - customFields: { - logos: { - Gruntwork: { - dark: "/logos/gruntwork.png", - light: "/logos/gruntwork-light.svg", - }, - Spacelift: { - dark: "/logos/spacelift.svg", - light: "/logos/spacelift-light.svg", - }, - env0: { dark: "/logos/env0.svg", light: "/logos/env0-light.svg" }, - Scalr: { dark: "/logos/scalr.svg", light: "/logos/scalr-light.png" }, - Harness: { - dark: "/logos/harness.svg", - light: "/logos/harness-light.png", - }, - }, - }, themes: [ [ diff --git a/src/components/Supporters/index.tsx b/src/components/Supporters/index.tsx index 20b42d0d..1beb2ef7 100644 --- a/src/components/Supporters/index.tsx +++ b/src/components/Supporters/index.tsx @@ -1,5 +1,4 @@ import React from "react"; -import useDocusaurusContext from "@docusaurus/useDocusaurusContext"; import supporters from "../../../supporters.json"; import Button from "../Button"; @@ -36,12 +35,12 @@ function SupporterType({ type, withSeparator, count }: SupporterTypeProps) { ); } +const MAX_LIST_COUNT = 5; + export default function Supporters() { - const { siteConfig } = useDocusaurusContext(); const groupedSupporters = groupSupportersByType(supporters); const types = Object.entries(groupedSupporters); - const { logos } = siteConfig.customFields; - const list = supporters.filter((supporter) => logos[supporter.name]); + const list = supporters.slice(0, MAX_LIST_COUNT); return (
diff --git a/src/components/SupportersList/index.tsx b/src/components/SupportersList/index.tsx index b1c87fbd..96a71382 100644 --- a/src/components/SupportersList/index.tsx +++ b/src/components/SupportersList/index.tsx @@ -1,8 +1,5 @@ import React from "react"; import Link from "@docusaurus/Link"; -import useDocusaurusContext from "@docusaurus/useDocusaurusContext"; -import ThemedImage from "@theme/ThemedImage"; -import useBaseUrl from "@docusaurus/useBaseUrl"; type SupportersListProps = { list: { @@ -14,9 +11,6 @@ type SupportersListProps = { }; export default function SupportersList({ list }: SupportersListProps) { - const { siteConfig } = useDocusaurusContext(); - const { logos } = siteConfig.customFields; - return (