Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: validation and other issues #30

Merged
merged 2 commits into from
Nov 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions apps/web/components/shared/header.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,23 @@ import { Button } from "@shadcdn/ui";
import Image from "next/image";
import Link from "next/link";

const Header = () => {
const Header = ({ isScrolled }) => {
return (
<header className="fixed flex w-full max-w-7xl items-start justify-between px-[5%] pb-6 pt-6">
<Image src="/borg/borg-id-logo.svg" width={88} height={30} className="mt-0.5" alt="Borg.id logo" />{" "}
<header
className="fixed flex w-full max-w-7xl items-start justify-between px-[5%] pb-6 pt-6"
style={
isScrolled
? {
background: "rgba(255,255,255,0.92)",
maskImage: "linear-gradient(to bottom, rgba(0,0,0,1) 35%, 50%, rgba(0,0,0,0))",
WebkitMaskImage: "linear-gradient(to bottom, rgba(0,0,0,1) 35%, 50%, rgba(0,0,0,0))",
backdropFilter: "blur(5px)",
}
: {}
}>
<Link href="/">
<Image src="/borg/borg-id-logo.svg" width={88} height={30} className="mt-0.5" alt="Borg.id logo" />{" "}
</Link>
<Button asChild className="">
<Link href="/auth/login">Log In</Link>
</Button>
Expand Down
2 changes: 1 addition & 1 deletion apps/web/pages/cookie-policy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import Footer from "@components/shared/footer";
import Header from "@components/shared/header";

const CookiePolicy = () => (
<div cla>
<div className="min-h-screen bg-white">
<NextSeo title="Cookie Policy - Borg.id" />
<Header />
<div className="mx-auto w-full max-w-[800px] pt-48">
Expand Down
14 changes: 7 additions & 7 deletions apps/web/pages/edit-profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ const EditProfile = () => {

if (socialLink?.id) {
updateSocialLinkMutation.mutate(socialLinkData);
} else {
} else if (socialLink?.url) {
addSocialLinkMutation.mutate(socialLinkData);
}
});
Expand All @@ -184,7 +184,7 @@ const EditProfile = () => {

if (fact?.id) {
updateFactMutation.mutate(factsData);
} else {
} else if (fact?.title) {
addFactMutation.mutate(factsData);
}
});
Expand All @@ -198,7 +198,7 @@ const EditProfile = () => {

if (project?.id) {
updateProjectMutation.mutate(projectData);
} else {
} else if (project?.title) {
addProjectMutation.mutate(projectData);
}
});
Expand All @@ -225,7 +225,7 @@ const EditProfile = () => {

if (pub?.id) {
updatePublicationMutation.mutate(pubData);
} else {
} else if (pub?.title) {
addPublicationMutation.mutate(pubData);
}
});
Expand All @@ -239,7 +239,7 @@ const EditProfile = () => {
if (book?.createdAt) {
removeBookMutation.mutate({ isbn: book.isbn });
addBookMutation.mutate(bookData);
} else {
} else if (book?.isbn) {
addBookMutation.mutate(bookData);
}
});
Expand All @@ -256,7 +256,7 @@ const EditProfile = () => {
};
if (app?.id) {
updateMediaAppearenceMutation.mutate(appData);
} else {
} else if (app?.title) {
addMediaAppearenceMutation.mutate(appData);
}
});
Expand All @@ -270,7 +270,7 @@ const EditProfile = () => {

if (podData?.id) {
updatePodcastMutation.mutate({ ...podData, id: podData.id });
} else {
} else if (pod?.title) {
addPodcastMutation.mutate(podData);
}
});
Expand Down
13 changes: 12 additions & 1 deletion apps/web/pages/impressum.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import Footer from "@components/shared/footer";
import Header from "@components/shared/header";

const Impressum = () => (
<div className="">
<div className="min-h-screen bg-white">
<NextSeo title="Impressum - Borg.id" />
<Header />
<div className="mx-auto w-full max-w-[800px] pt-48">
Expand All @@ -23,6 +23,7 @@ const Impressum = () => (
Collective GmbH represented by its responsible Managing Director (Geschäftsführer) Maciej
Laskus.
</p>
<br />
<p>Contact details:</p>
<span>Borg Collective GmbH</span>
<br />
Expand Down Expand Up @@ -58,6 +59,7 @@ const Impressum = () => (
<br />
<br />
</li>
<br />
<li>
<p>
<strong>Online Dispute Resolution.</strong>
Expand All @@ -69,6 +71,7 @@ const Impressum = () => (
process.
</p>
</li>
<br />
<li>
<p>
<strong>Liability For Contents.</strong>
Expand All @@ -81,19 +84,22 @@ const Impressum = () => (
any damages of any material or notional nature caused by making use of the service, unless
this can be shown to have been caused by deliberate intent or gross negligence.
</p>
<br />
<p>
The laws, regulations and directives which might in certain cases be published in this
Internet offer have been compiled with care, however no claim is made to their being fully up
to date or complete. The current wording is legally binding as it appears in the relevant
publication organs (in particular the Bulletin of the Federal State of North Rhine-Westphalia,
Official Gazette).
</p>
<br />
<p>
This Internet offer makes reference to numerous offers on the Internet. The contents of the
linked pages are created by, among other bodies, companies and institutions over which Borg
Collective GmbH has no influence. Borg Collective GmbH does not claim the contents contained
in these as its own. Absolutely no liability is accepted for third-party offers.
</p>
<br />
<p>
If in respect of the pages of this Internet offer or pages to which reference is made, you
should identify dubious or illegal content, Borg Collective GmbH would be grateful if you
Expand All @@ -102,6 +108,7 @@ const Impressum = () => (
any specific notice. The temporary suspension or definitive termination of publication is also
possible without notice.
</p>
<br />
<p>
In accordance with § 7 Para. 1 of the Telemedia Act, Borg Collective GmbH is responsible for
its own content in this site under the general legal regulations. Under the terms of §§ 8 to
Expand All @@ -115,6 +122,7 @@ const Impressum = () => (
immediately.
</p>
</li>
<br />
<li>
<p>
<strong>Copyright And Rights Of Use.</strong>
Expand All @@ -129,6 +137,7 @@ const Impressum = () => (
and eliminate the breach of law.
</p>
</li>
<br />
<li>
<p>
<strong>Data Protection Conditions.</strong>
Expand All @@ -140,6 +149,7 @@ const Impressum = () => (
by Borg Collective GmbH.
</p>
</li>
<br />
<li>
<p>
<strong>Data Storage.</strong>
Expand All @@ -155,6 +165,7 @@ const Impressum = () => (
elements on HTML pages (JavaScript, ActiveX, etc.).
</p>
</li>
<br />
<li>
<p>
<strong>Data Transmission.</strong>
Expand Down
64 changes: 4 additions & 60 deletions apps/web/pages/landing/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@ import type { StaticImageData } from "next/image";
import Image from "next/image";
import Link from "next/link";
import { useEffect, useState } from "react";
import { Envelope, Twitter } from "react-bootstrap-icons";

import { HeadSeo } from "@calcom/ui";

import PageWrapper from "@components/PageWrapper";
import Footer from "@components/shared/footer";
import Header from "@components/shared/header";

// For some reason, tailwind JIT doesn't work with dynamic classes
// if they are generated in a function
Expand Down Expand Up @@ -142,25 +143,7 @@ const LandingPage = () => {
/>
<div className="flex w-full flex-col items-center bg-white font-sans">
{/* Header */}
<header
className="fixed flex w-full max-w-7xl items-start justify-between px-[5%] pb-6 pt-6"
style={
isScrolled
? {
background: "rgba(255,255,255,0.92)",
maskImage: "linear-gradient(to bottom, rgba(0,0,0,1) 35%, 50%, rgba(0,0,0,0))",
WebkitMaskImage: "linear-gradient(to bottom, rgba(0,0,0,1) 35%, 50%, rgba(0,0,0,0))",
backdropFilter: "blur(5px)",
}
: {}
}>
<Image src="/borg/borg-id-logo.svg" width={88} height={30} className="mt-0.5" alt="Borg.id logo" />{" "}
{/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
{/* @ts-ignore */}
<Button asChild className="">
<Link href="/auth/login">Log In</Link>
</Button>
</header>
<Header isScrolled={isScrolled} />
<main className="flex w-full flex-col items-center">
{/* Hero */}
<div
Expand Down Expand Up @@ -352,46 +335,7 @@ const LandingPage = () => {
</div>

{/* Footer */}
<footer className="flex w-full max-w-7xl flex-col gap-10 px-[5%] pb-4 pt-10 md:gap-6 md:pt-14">
<div
className="grid w-full grid-flow-dense gap-y-10 md:gap-y-0"
style={{ gridTemplateColumns: "repeat(12, minmax(0, 1fr))" }}>
<Image
src="/borg/borg-id-logo.svg"
width={88}
height={30}
className="col-span-6 md:col-span-7 lg:col-span-9"
alt="Borg.id logo"
/>
<div className="col-span-12 flex flex-row flex-wrap justify-center gap-x-6 gap-y-0 md:col-span-3 md:flex-col md:gap-3 lg:col-span-2">
{/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
{/* @ts-ignore */}
<Button variant="link" size="sm" className="w-max px-0">
Privacy Policy
</Button>
{/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
{/* @ts-ignore */}
<Button variant="link" size="sm" className="w-max px-0">
Cookie Policy
</Button>
{/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
{/* @ts-ignore */}
<Button variant="link" size="sm" className="w-max px-0">
Impressum
</Button>
{/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
{/* @ts-ignore */}
<Button variant="link" size="sm" className="w-max px-0">
Terms & Conditions
</Button>
</div>
<div className="col-span-6 flex h-9 items-center justify-end gap-6 md:col-span-2 lg:col-span-1">
<Twitter size={16} />
<Envelope size={16} />
</div>
</div>
<div className="text-landing-xs">Copyright © 2023 Borg Collective GmbH. All rights reserved.</div>
</footer>
<Footer />
</main>
</div>
</>
Expand Down
2 changes: 1 addition & 1 deletion apps/web/pages/privacy-policy.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import Footer from "@components/shared/footer";
import Header from "@components/shared/header";

const PrivacyPolicy = () => (
<div className="">
<div className="min-h-screen bg-white">
<NextSeo title="Privacy Policy - Borg.id" />
<Header />
<div className="mx-auto w-full max-w-[800px] pt-48">
Expand Down
2 changes: 1 addition & 1 deletion apps/web/pages/terms-conditions.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import Footer from "@components/shared/footer";
import Header from "@components/shared/header";

const TermsConditions = () => (
<div className="">
<div className="min-h-screen bg-white">
<NextSeo title="Terms & Conditions - Borg.id" />
<Header />
<div className="mx-auto w-full max-w-[800px] pt-48">
Expand Down
4 changes: 2 additions & 2 deletions apps/web/pages/zoom-support.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import Footer from "@components/shared/footer";
import Header from "@components/shared/header";

const ZoomSupport = () => (
<div className="">
<NextSeo title="Impressum - Borg.id" />
<div className="min-h-screen bg-white">
<NextSeo title="Zoom Support - Borg.id" />
<Header />
<div className="mx-auto w-full max-w-[800px] pt-48">
<div>
Expand Down
1 change: 1 addition & 0 deletions apps/web/ui/valery/podcast-item.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import Link from "next/link";
import ExternalLinkIcon from "../../ui/icons/external-link-icon";

const PodcastItem = ({ podcast }) => {
if (!podcast?.title) return null;
return (
<div>
<div className="mt-3 grid grid-cols-[120px_1fr] gap-3">
Expand Down
Loading