Skip to content

Commit

Permalink
Fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
souljja committed May 26, 2024
1 parent 07882c0 commit c020d05
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 32 deletions.
1 change: 0 additions & 1 deletion next-env.d.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
/// <reference types="next/navigation-types/compat/navigation" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.
File renamed without changes.
22 changes: 17 additions & 5 deletions src/app/[locale]/[slug]/not-found.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
"use client";
import { Title } from "@/components/title/title.tsx";
import { Typography } from "@/components/typography/typography.tsx";
import "./not-found.scss";

import Error from "next/error";
export interface NotFoundProps {
title: string;
description: string;
}

const NotFound = ({ title, description }: NotFoundProps) => (
<section className="not-found">
<Title as="h1" className="not-found-title">
{title}
</Title>
<Typography className="not-found-description">{description}</Typography>
</section>
);

// eslint-disable-next-line import/no-default-export,react/function-component-definition
export default function NotFound() {
return <Error statusCode={404} />;
}
export default NotFound;
6 changes: 5 additions & 1 deletion src/app/[locale]/[slug]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ export default async function Home({
{renderSection(section as PagePageSectionsDynamicZone)}
</Fragment>
))}
{/* eslint-disable */}
<div className="sp-form-outer sp-force-hide">
<div
id="sp-form-235327"
Expand All @@ -135,7 +136,7 @@ export default async function Home({
<div className="sp-message">
<div></div>
</div>
<form noValidate="" className="sp-element-container ">
<form noValidate className="sp-element-container ">
<div
className="sp-field "
sp-id="sp-5c47ba76-ed95-48e7-a86d-7e2a7860d63b"
Expand All @@ -152,6 +153,7 @@ export default async function Home({
placeholder="Ivan"
sp-tips="%7B%22required%22%3A%22Required%20field%22%7D"
autoComplete="on"
// @ts-ignore
required="required"
/>
</div>
Expand All @@ -171,6 +173,7 @@ export default async function Home({
placeholder="[email protected]"
sp-tips="%7B%22required%22%3A%22Required%20field%22%2C%22wrong%22%3A%22Wrong%20email%22%7D"
autoComplete="on"
// @ts-ignore
required="required"
/>
</div>
Expand All @@ -195,6 +198,7 @@ export default async function Home({
async
src="//web.webformscr.com/apps/fc3/build/default-handler.js?1714030486793"
/>
{/* eslint-enable */}
</>
);
}
17 changes: 0 additions & 17 deletions src/pages/not-found/not-found.tsx

This file was deleted.

9 changes: 1 addition & 8 deletions src/utils/get-application-root.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
export const getApplicationRoot = () => {
// const root = document.querySelector("#root");
//
// if (!root) {
// throw new Error("Application root is not found");
// }
//
// return root;
return document.body
return document.body;
};

0 comments on commit c020d05

Please sign in to comment.