From 381082906893c68462035bd3f955d319a7762818 Mon Sep 17 00:00:00 2001 From: hhack Date: Tue, 11 Oct 2022 10:16:01 +0200 Subject: [PATCH 1/8] add new banner component file --- pages/_app.tsx | 2 ++ src/components/Banner/index.tsx | 10 ++++++++++ 2 files changed, 12 insertions(+) create mode 100644 src/components/Banner/index.tsx diff --git a/pages/_app.tsx b/pages/_app.tsx index ffec2e8..7149f8d 100644 --- a/pages/_app.tsx +++ b/pages/_app.tsx @@ -1,6 +1,7 @@ import { mapRawQueryToState } from '@lib/utils/queryUtil' import { ParsedUrlQuery } from 'querystring' import { StrictMode, FC } from 'react' +import { Banner } from '@components/Banner' import { Head } from '@components/Head' import '../src/style/global.css' import { useMatomo } from '@lib/hooks/useMatomo' @@ -30,6 +31,7 @@ const App: FC<{ return ( + {pathname !== '/share' &&
} diff --git a/src/components/Banner/index.tsx b/src/components/Banner/index.tsx new file mode 100644 index 0000000..ad7d922 --- /dev/null +++ b/src/components/Banner/index.tsx @@ -0,0 +1,10 @@ +import { FC } from 'react' +// import React, { useState } from 'react' + +export const Banner: FC = () => { + // const [showBanner, setShowBanner] = useState(true) + // const hideBanner = (): void => { + // setShowBanner(false) + // } + return
+} From 1c87ffb0225b0bc4aec5683baff760af15c8426c Mon Sep 17 00:00:00 2001 From: hhack Date: Tue, 11 Oct 2022 13:54:27 +0200 Subject: [PATCH 2/8] banner content --- src/components/Banner/index.tsx | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/src/components/Banner/index.tsx b/src/components/Banner/index.tsx index ad7d922..4aef0ee 100644 --- a/src/components/Banner/index.tsx +++ b/src/components/Banner/index.tsx @@ -1,10 +1,28 @@ -import { FC } from 'react' -// import React, { useState } from 'react' +import { FC, useState } from 'react' +// import { Button } from '@components/Button' +import { Cross } from '@components/Icons' export const Banner: FC = () => { - // const [showBanner, setShowBanner] = useState(true) - // const hideBanner = (): void => { - // setShowBanner(false) - // } - return
+ const [showBanner, setShowBanner] = useState(true) + const hideBanner = (): void => { + setShowBanner(false) + } + + return showBanner ? ( +
+

+ Liebe Developer, + am 23.11.22 um 19 Uhr findet im CityLAB Berlin das nächste Developer + Meetup statt. Du bist herzlich willkommen, uns über die Schulter zu + schauen und selbst aktiv mitzumachen. Wir freuen uns auf euch! +

+ {/* */} + +
+ ) : null } From 43011a5e431f0ef73c04078e8d840f7ad91d44c1 Mon Sep 17 00:00:00 2001 From: hhack Date: Wed, 12 Oct 2022 14:18:45 +0200 Subject: [PATCH 3/8] content and layout --- src/components/Banner/index.tsx | 26 ++++++++++++++++---------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/src/components/Banner/index.tsx b/src/components/Banner/index.tsx index 4aef0ee..fdfd16c 100644 --- a/src/components/Banner/index.tsx +++ b/src/components/Banner/index.tsx @@ -1,5 +1,5 @@ import { FC, useState } from 'react' -// import { Button } from '@components/Button' +import { Button } from '@components/Button' import { Cross } from '@components/Icons' export const Banner: FC = () => { @@ -9,20 +9,26 @@ export const Banner: FC = () => { } return showBanner ? ( -
-

- Liebe Developer, - am 23.11.22 um 19 Uhr findet im CityLAB Berlin das nächste Developer - Meetup statt. Du bist herzlich willkommen, uns über die Schulter zu - schauen und selbst aktiv mitzumachen. Wir freuen uns auf euch! -

- {/* */} +
+
+

+ Liebe Developer, + am 23.11.22 um 19 Uhr findet im CityLAB Berlin das nächste Developer + Meetup statt. +
+ Du bist herzlich willkommen, uns über die Schulter zu schauen und + selbst aktiv mitzumachen. Wir freuen uns auf euch! +

+ + + +
) : null } From a7960f8e52de065d9be467b1d31de3892040938c Mon Sep 17 00:00:00 2001 From: hhack Date: Wed, 12 Oct 2022 14:21:37 +0200 Subject: [PATCH 4/8] simplify code --- src/components/Banner/index.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/components/Banner/index.tsx b/src/components/Banner/index.tsx index fdfd16c..bd02288 100644 --- a/src/components/Banner/index.tsx +++ b/src/components/Banner/index.tsx @@ -4,14 +4,11 @@ import { Cross } from '@components/Icons' export const Banner: FC = () => { const [showBanner, setShowBanner] = useState(true) - const hideBanner = (): void => { - setShowBanner(false) - } return showBanner ? (
-
+

Liebe Developer, am 23.11.22 um 19 Uhr findet im CityLAB Berlin das nächste Developer From b77793c678a9b3fa0e82fd5d1e31c718bbc212fa Mon Sep 17 00:00:00 2001 From: hhack Date: Fri, 14 Oct 2022 10:19:38 +0200 Subject: [PATCH 6/8] layout and color --- src/components/Banner/index.tsx | 6 +++--- src/style/colors.js | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/components/Banner/index.tsx b/src/components/Banner/index.tsx index e306421..48fd0b8 100644 --- a/src/components/Banner/index.tsx +++ b/src/components/Banner/index.tsx @@ -6,14 +6,14 @@ export const Banner: FC = () => { const [showBanner, setShowBanner] = useState(true) return showBanner ? ( -

+
-
+

Liebe Developer, am 23.11.22 um 19 Uhr findet im CityLAB Berlin das nächste Developer @@ -22,7 +22,7 @@ export const Banner: FC = () => { Du bist herzlich willkommen, uns über die Schulter zu schauen und selbst aktiv mitzumachen. Wir freuen uns auf euch!

- +
diff --git a/src/style/colors.js b/src/style/colors.js index 4a1471d..96f9c8d 100644 --- a/src/style/colors.js +++ b/src/style/colors.js @@ -29,6 +29,7 @@ const colors = Object.assign( '900': '#111827', }, brand: '#c41b31', + blue: '#324FA3', }, palette ) From f5b35ca30cc525cac7f99068fb376d7b642c6cd8 Mon Sep 17 00:00:00 2001 From: hhack Date: Wed, 26 Oct 2022 16:25:32 +0200 Subject: [PATCH 7/8] added proper link to meetup --- src/components/Banner/index.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/components/Banner/index.tsx b/src/components/Banner/index.tsx index 48fd0b8..9e176a1 100644 --- a/src/components/Banner/index.tsx +++ b/src/components/Banner/index.tsx @@ -23,7 +23,11 @@ export const Banner: FC = () => { selbst aktiv mitzumachen. Wir freuen uns auf euch!

- +
From 2f75a89dea06911dd8e445984ff1b7d27d5da9fb Mon Sep 17 00:00:00 2001 From: hhack Date: Wed, 26 Oct 2022 16:51:06 +0200 Subject: [PATCH 8/8] do not show banner in iframe --- pages/_app.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/_app.tsx b/pages/_app.tsx index 7149f8d..847e109 100644 --- a/pages/_app.tsx +++ b/pages/_app.tsx @@ -31,7 +31,7 @@ const App: FC<{ return ( - + {pathname !== '/share' && } {pathname !== '/share' &&
}