From 5b4ff8dab4ca2f23be4c9c915e28bfb9f04abea3 Mon Sep 17 00:00:00 2001 From: Kieran O'Neill Date: Wed, 15 Nov 2023 16:12:57 +0000 Subject: [PATCH] refactor: rename vision to concepts --- docusaurus.config.js | 10 ++++----- .../ConceptItem.tsx} | 4 ++-- .../ConceptsSection.tsx} | 22 +++++++++---------- src/components/ConceptsSection/index.ts | 3 +++ .../styles.module.scss | 0 .../types/IConceptItemProps.ts} | 4 ++-- src/components/ConceptsSection/types/index.ts | 1 + src/components/VisionSection/index.ts | 3 --- src/components/VisionSection/types/index.ts | 1 - src/pages/index.tsx | 6 ++--- .../{feature_001.svg => concept_001.svg} | 0 .../{feature_002.svg => concept_002.svg} | 0 .../{feature_003.svg => concept_003.svg} | 0 13 files changed, 27 insertions(+), 27 deletions(-) rename src/components/{VisionSection/VisionItem.tsx => ConceptsSection/ConceptItem.tsx} (91%) rename src/components/{VisionSection/VisionSection.tsx => ConceptsSection/ConceptsSection.tsx} (72%) create mode 100644 src/components/ConceptsSection/index.ts rename src/components/{VisionSection => ConceptsSection}/styles.module.scss (100%) rename src/components/{VisionSection/types/IVisionItemProps.ts => ConceptsSection/types/IConceptItemProps.ts} (72%) create mode 100644 src/components/ConceptsSection/types/index.ts delete mode 100644 src/components/VisionSection/index.ts delete mode 100644 src/components/VisionSection/types/index.ts rename static/images/{feature_001.svg => concept_001.svg} (100%) rename static/images/{feature_002.svg => concept_002.svg} (100%) rename static/images/{feature_003.svg => concept_003.svg} (100%) diff --git a/docusaurus.config.js b/docusaurus.config.js index 77e0c71..1734efb 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -94,14 +94,14 @@ const config = { // right { items: [ - { - label: 'Vision', - to: '#vision', - }, { label: 'Features', to: '#features', }, + { + label: 'Concepts', + to: '#concepts', + }, ], label: 'Overview', position: 'right', @@ -127,7 +127,7 @@ const config = { title: 'Learn More', items: [ { - label: 'Learn', + label: 'Docs', to: '/docs/intro', }, { diff --git a/src/components/VisionSection/VisionItem.tsx b/src/components/ConceptsSection/ConceptItem.tsx similarity index 91% rename from src/components/VisionSection/VisionItem.tsx rename to src/components/ConceptsSection/ConceptItem.tsx index ae77bf6..a48dfb6 100644 --- a/src/components/VisionSection/VisionItem.tsx +++ b/src/components/ConceptsSection/ConceptItem.tsx @@ -12,7 +12,7 @@ import { IVisionItemProps } from './types'; type IProps = IVisionItemProps; -const VisionItem: FC = ({ +const ConceptItem: FC = ({ title, SvgComponent, description, @@ -31,4 +31,4 @@ const VisionItem: FC = ({ ); }; -export default VisionItem; +export default ConceptItem; diff --git a/src/components/VisionSection/VisionSection.tsx b/src/components/ConceptsSection/ConceptsSection.tsx similarity index 72% rename from src/components/VisionSection/VisionSection.tsx rename to src/components/ConceptsSection/ConceptsSection.tsx index c54dadf..10fa214 100644 --- a/src/components/VisionSection/VisionSection.tsx +++ b/src/components/ConceptsSection/ConceptsSection.tsx @@ -2,12 +2,12 @@ import React, { FC } from 'react'; // components import Section from '@site/src/components/Section'; -import VisionItem from './VisionItem'; +import ConceptItem from './ConceptItem'; // images -import feature001Svg from '@site/static/images/feature_001.svg'; -import feature002Svg from '@site/static/images/feature_002.svg'; -import feature003Svg from '@site/static/images/feature_003.svg'; +import concept001Svg from '@site/static/images/concept_001.svg'; +import concept002Svg from '@site/static/images/concept_002.svg'; +import concept003Svg from '@site/static/images/concept_003.svg'; // styles import styles from './styles.module.scss'; @@ -18,11 +18,11 @@ import { IVisionItemProps } from './types'; type IProps = IDefaultSectionProps; -const VisionSection: FC = ({ variant }: IProps) => { +const ConceptsSection: FC = ({ variant }: IProps) => { const items: IVisionItemProps[] = [ { title: 'Not Just For DeFi', - SvgComponent: feature001Svg, + SvgComponent: concept001Svg, description: ( <> Kibisis differs from most wallets by focusing on tokens as a utility, @@ -32,7 +32,7 @@ const VisionSection: FC = ({ variant }: IProps) => { }, { title: 'AVM Compatible', - SvgComponent: feature002Svg, + SvgComponent: concept002Svg, description: ( <> Kibisis not only works with Algorand, but endeavours to encompass all @@ -42,7 +42,7 @@ const VisionSection: FC = ({ variant }: IProps) => { }, { title: 'Browser Extension', - SvgComponent: feature003Svg, + SvgComponent: concept003Svg, description: ( <> Leveraging the security and convenience of browser extensions, Kibisis @@ -53,10 +53,10 @@ const VisionSection: FC = ({ variant }: IProps) => { ]; return ( -
+
{items.map(({ description, SvgComponent, title }, index) => ( - = ({ variant }: IProps) => { ); }; -export default VisionSection; +export default ConceptsSection; diff --git a/src/components/ConceptsSection/index.ts b/src/components/ConceptsSection/index.ts new file mode 100644 index 0000000..89be340 --- /dev/null +++ b/src/components/ConceptsSection/index.ts @@ -0,0 +1,3 @@ +export { default } from './ConceptsSection'; +export { default as ConceptItem } from './ConceptItem'; +export * from './types'; diff --git a/src/components/VisionSection/styles.module.scss b/src/components/ConceptsSection/styles.module.scss similarity index 100% rename from src/components/VisionSection/styles.module.scss rename to src/components/ConceptsSection/styles.module.scss diff --git a/src/components/VisionSection/types/IVisionItemProps.ts b/src/components/ConceptsSection/types/IConceptItemProps.ts similarity index 72% rename from src/components/VisionSection/types/IVisionItemProps.ts rename to src/components/ConceptsSection/types/IConceptItemProps.ts index 57304d2..9fa3f91 100644 --- a/src/components/VisionSection/types/IVisionItemProps.ts +++ b/src/components/ConceptsSection/types/IConceptItemProps.ts @@ -1,9 +1,9 @@ import { ComponentProps, ComponentType, ReactElement } from 'react'; -interface IVisionItemProps { +interface IConceptItemProps { SvgComponent: ComponentType>; description: ReactElement; title: string; } -export default IVisionItemProps; +export default IConceptItemProps; diff --git a/src/components/ConceptsSection/types/index.ts b/src/components/ConceptsSection/types/index.ts new file mode 100644 index 0000000..f4a2b15 --- /dev/null +++ b/src/components/ConceptsSection/types/index.ts @@ -0,0 +1 @@ +export { default as IVisionItemProps } from './IConceptItemProps'; diff --git a/src/components/VisionSection/index.ts b/src/components/VisionSection/index.ts deleted file mode 100644 index 4bdf277..0000000 --- a/src/components/VisionSection/index.ts +++ /dev/null @@ -1,3 +0,0 @@ -export { default } from './VisionSection'; -export { default as Feature } from './VisionItem'; -export * from './types'; diff --git a/src/components/VisionSection/types/index.ts b/src/components/VisionSection/types/index.ts deleted file mode 100644 index 828d05a..0000000 --- a/src/components/VisionSection/types/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { default as IVisionItemProps } from './IVisionItemProps'; diff --git a/src/pages/index.tsx b/src/pages/index.tsx index b75e432..4118896 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -4,10 +4,10 @@ import React, { FC } from 'react'; import Layout from '@theme/Layout'; // components +import ConceptsSection from '@site/src/components/ConceptsSection'; import FeaturesSection from '@site/src/components/FeaturesSection'; import Header from '@site/src/components/Header'; import Main from '@site/src/components/Main'; -import VisionSection from '@site/src/components/VisionSection'; const IndexPage: FC = () => { const { siteConfig } = useDocusaurusContext(); @@ -20,9 +20,9 @@ const IndexPage: FC = () => {
- + - +
); diff --git a/static/images/feature_001.svg b/static/images/concept_001.svg similarity index 100% rename from static/images/feature_001.svg rename to static/images/concept_001.svg diff --git a/static/images/feature_002.svg b/static/images/concept_002.svg similarity index 100% rename from static/images/feature_002.svg rename to static/images/concept_002.svg diff --git a/static/images/feature_003.svg b/static/images/concept_003.svg similarity index 100% rename from static/images/feature_003.svg rename to static/images/concept_003.svg