From 11f684b88064b0d2d0608add565d6a31c3f7f364 Mon Sep 17 00:00:00 2001 From: Charlie85270 Date: Mon, 30 Oct 2023 13:56:50 -0400 Subject: [PATCH] remove pub --- components/layout/AppLayout.tsx | 6 ------ components/layout/ComponentLayout.tsx | 17 --------------- components/site/Pub/Banner.tsx | 28 ------------------------- components/site/Pub/SquarePub.tsx | 24 --------------------- components/site/section/SectionDesc.tsx | 2 -- pages/started/index.tsx | 2 -- 6 files changed, 79 deletions(-) delete mode 100644 components/site/Pub/Banner.tsx delete mode 100644 components/site/Pub/SquarePub.tsx diff --git a/components/layout/AppLayout.tsx b/components/layout/AppLayout.tsx index 8d724a3..f7ab4e3 100644 --- a/components/layout/AppLayout.tsx +++ b/components/layout/AppLayout.tsx @@ -1,7 +1,6 @@ import FooterLight from '../kit/components/navigation/footer/FooterLight'; import Meta from '../site/Meta'; import AppHeader from '../site/header/AppHeader'; -import AdBanner from '../site/Pub/Banner'; const footerLink = [ { @@ -91,11 +90,6 @@ const AppLayout = ({ title, desc, children, withPub }: Props) => { > {children} - {withPub && ( -
- -
- )}
diff --git a/components/layout/ComponentLayout.tsx b/components/layout/ComponentLayout.tsx index 30d795d..4e7f452 100644 --- a/components/layout/ComponentLayout.tsx +++ b/components/layout/ComponentLayout.tsx @@ -8,7 +8,6 @@ import Link from 'next/link'; import ReactDOMServer from 'react-dom/server'; import Toggle from '../kit/components/form/toggle/Toggle'; import { formatHtml } from '../../utils/Utils'; -import AdBanner from '../site/Pub/Banner'; interface Props { element: JSX.Element; @@ -206,22 +205,6 @@ const ComponentLayout = (props: Props) => {
- {props.withPub && ( -
-
-

Publicity

- -
-
- -
-
- )} ); }; diff --git a/components/site/Pub/Banner.tsx b/components/site/Pub/Banner.tsx deleted file mode 100644 index 23ce4af..0000000 --- a/components/site/Pub/Banner.tsx +++ /dev/null @@ -1,28 +0,0 @@ -import React, { useEffect } from 'react'; - -interface Props { - isVertical?: boolean; -} - -const AdBanner = ({ isVertical }: Props) => { - useEffect(() => { - try { - ((window as any).adsbygoogle = (window as any).adsbygoogle || []).push({}); - } catch (err) { - console.log(err); - } - }, []); - - return ( - - ); -}; - -export default AdBanner; diff --git a/components/site/Pub/SquarePub.tsx b/components/site/Pub/SquarePub.tsx deleted file mode 100644 index 8ae54b4..0000000 --- a/components/site/Pub/SquarePub.tsx +++ /dev/null @@ -1,24 +0,0 @@ -import React, { useEffect } from 'react'; - -const SquarePub = () => { - useEffect(() => { - try { - ((window as any).adsbygoogle = (window as any).adsbygoogle || []).push({}); - } catch (err) { - console.log(err); - } - }, []); - - return ( - - ); -}; - -export default SquarePub; diff --git a/components/site/section/SectionDesc.tsx b/components/site/section/SectionDesc.tsx index 9699533..7a15f0b 100644 --- a/components/site/section/SectionDesc.tsx +++ b/components/site/section/SectionDesc.tsx @@ -1,7 +1,6 @@ import React from 'react'; import Link from 'next/link'; import Badge from '../../kit/components/elements/badges/Badge'; -import SquarePub from '../Pub/SquarePub'; interface Props { items: section[]; @@ -79,7 +78,6 @@ const SectionDesc = ({ title, items, id, hasCommingSoon, isTemplate, withPub }: )} - {withPub && } ); }; diff --git a/pages/started/index.tsx b/pages/started/index.tsx index d6fb459..85e0b59 100644 --- a/pages/started/index.tsx +++ b/pages/started/index.tsx @@ -3,7 +3,6 @@ import AppLayout from '../../components/layout/AppLayout'; import { LiveProvider, LiveEditor } from 'react-live'; import EDITOR_THEME from '../../editorTheme'; import Link from 'next/link'; -import SquarePub from '../../components/site/Pub/SquarePub'; const confCode = `module.exports = { important: true, @@ -100,7 +99,6 @@ const StartedPage: FC = () => { -