Merge branch 'main' into next

This commit is contained in:
Lucas Smith
2023-05-30 19:55:31 +10:00
committed by GitHub
13 changed files with 241 additions and 50 deletions

View File

@ -3,11 +3,11 @@ import Link from "next/link";
import { useRouter } from "next/router";
import { NEXT_PUBLIC_WEBAPP_URL } from "@documenso/lib/constants";
import { useSubscription } from "@documenso/lib/stripe";
import { BillingWarning } from "./billing-warning";
import Navigation from "./navigation";
import { PaperAirplaneIcon } from "@heroicons/react/24/outline";
import { SubscriptionStatus } from "@prisma/client";
import { useSession } from "next-auth/react";
import { BillingWarning } from "./billing-warning";
function useRedirectToLoginIfUnauthenticated() {
const { data: session, status } = useSession();

View File

@ -1,6 +1,7 @@
import { ReactElement, ReactNode } from "react";
import { NextPage } from "next";
import type { AppProps } from "next/app";
import { Montserrat, Qwigley } from "next/font/google";
import { SubscriptionProvider } from "@documenso/lib/stripe/providers/subscription-provider";
import "../../../node_modules/placeholder-loading/src/scss/placeholder-loading.scss";
import "../../../node_modules/react-resizable/css/styles.css";
@ -11,6 +12,20 @@ import "react-tooltip/dist/react-tooltip.css";
export { coloredConsole } from "@documenso/lib";
const montserrat = Montserrat({
subsets: ["latin"],
weight: ["400", "700"],
display: "swap",
variable: "--font-sans",
});
const qwigley = Qwigley({
subsets: ["latin"],
weight: ["400"],
display: "swap",
variable: "--font-qwigley",
});
export type NextPageWithLayout<P = {}, IP = P> = NextPage<P, IP> & {
getLayout?: (page: ReactElement) => ReactNode;
};
@ -27,8 +42,10 @@ export default function App({
return (
<SessionProvider session={session}>
<SubscriptionProvider initialSubscription={initialSubscription}>
<Toaster position="top-center" />
{getLayout(<Component {...pageProps} />)}
<main className={`${montserrat.variable} h-full font-sans`}>
<Toaster position="top-center" />
{getLayout(<Component {...pageProps} />)}
</main>
</SubscriptionProvider>
</SessionProvider>
);

View File

@ -6,35 +6,3 @@
min-height: 100%;
}
html,
body,
:host {
font-family: montserrat;
}
@font-face {
font-family: "Qwigley";
src: url("/fonts/Qwigley-Regular.ttf");
}
/* latin */
@font-face {
font-family: "Montserrat";
font-style: normal;
font-weight: 400;
font-display: swap;
src: url("/fonts/montserrat.woff2") format("woff2");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F,
U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin */
@font-face {
font-family: "Montserrat";
font-style: normal;
font-weight: 700;
font-display: swap;
src: url("/fonts/montserrat.woff2") format("woff2");
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F,
U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

View File

@ -12,8 +12,8 @@ module.exports = {
theme: {
extend: {
fontFamily: {
monteserrat: ["Monteserrat", "serif"],
qwigley: ["Qwigley", "serif"],
sans: ["var(--font-sans)", ...defaultTheme.fontFamily.sans],
qwigley: ["var(--font-qwigley)", "serif"],
},
colors: {
neon: {
@ -58,6 +58,19 @@ module.exports = {
900: "#000000",
950: "#000000",
},
brand: {
DEFAULT: "#A2E771",
100: "#F4FCEE",
200: "#E8F9DC",
300: "#D1F3B9",
400: "#BBED96",
500: "#A2E771",
600: "#8DE151",
700: "#76DC2E",
800: "#63C021",
900: "#519D1B",
950: "#488C18",
},
},
borderRadius: {
"4xl": "2rem",