Skip to content

Commit

Permalink
refactor: purge contact form
Browse files Browse the repository at this point in the history
  • Loading branch information
mathiazom committed Oct 10, 2024
1 parent 315db19 commit 761f99b
Show file tree
Hide file tree
Showing 9 changed files with 2 additions and 1,023 deletions.
623 changes: 2 additions & 621 deletions package-lock.json

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"test-storybook": "test-storybook"
},
"dependencies": {
"@google-cloud/pubsub": "^4.5.0",
"@sanity/document-internationalization": "^3.0.1",
"@sanity/image-url": "^1.0.2",
"@sanity/preview-url-secret": "^1.6.11",
Expand Down
57 changes: 0 additions & 57 deletions src/app/api/contactForm/route.ts

This file was deleted.

190 changes: 0 additions & 190 deletions src/components/sections/contactForm/ContactForm.tsx

This file was deleted.

83 changes: 0 additions & 83 deletions src/components/sections/contactForm/contactForm.module.css

This file was deleted.

16 changes: 0 additions & 16 deletions src/utils/renderSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import Callout from "src/components/sections/callout/Callout";
import CalloutPreview from "src/components/sections/callout/CalloutPreview";
import CallToAction from "src/components/sections/callToAction/CallToAction";
import CallToActionPreview from "src/components/sections/callToAction/CallToActionPreview";
import ContactForm from "src/components/sections/contactForm/ContactForm";
import Grid from "src/components/sections/grid/Grid";
import GridPreview from "src/components/sections/grid/GridPreview";
import { Hero } from "src/components/sections/hero/Hero";
Expand All @@ -22,7 +21,6 @@ import {
ArticleSection,
CallToActionSection,
CalloutSection,
ContactFormSection,
GridSection,
HeroSection,
ImageSection,
Expand Down Expand Up @@ -158,14 +156,6 @@ const renderGridSection = (
);
};

const renderContactFormSection = (
section: ContactFormSection,
sectionIndex: number,
isDraftMode: boolean,
) => {
return isDraftMode ? <div></div> : <ContactForm data={section} />;
};

const SectionRenderer = ({
section,
sectionIndex,
Expand Down Expand Up @@ -231,12 +221,6 @@ const SectionRenderer = ({
isDraftMode,
initialData,
);
case "contactForm":
return renderContactFormSection(
section as ContactFormSection,
sectionIndex,
isDraftMode,
);
default:
return null;
}
Expand Down
7 changes: 0 additions & 7 deletions studio/lib/interfaces/pages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,6 @@ export interface GridSection {
}[];
}

export interface ContactFormSection {
_key: string;
_type: string;
basicTitle: string;
checkboxLabel: PortableTextBlock[];
}

export type Section =
| HeroSection
| LogoSaladSection
Expand Down
Loading

0 comments on commit 761f99b

Please sign in to comment.