Skip to content

Commit

Permalink
[W-16] Centralize tailwind config, use inter (#26)
Browse files Browse the repository at this point in the history
* use inter

* update docs logo svg

* centralize tailwind config

* missing files
  • Loading branch information
markflorkowski authored Jan 28, 2023
1 parent 7862d2a commit 74db096
Show file tree
Hide file tree
Showing 18 changed files with 387 additions and 205 deletions.
2 changes: 2 additions & 0 deletions packages/cli/cli-web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
"preview": "vite preview"
},
"dependencies": {
"@captain/tailwind-config": "*",
"@headlessui/react": "^1.7.8",
"@heroicons/react": "^2.0.12",
"@tanstack/react-query": "^4.7.2",
"@trpc/client": "10.0.0-proxy-beta.25",
Expand Down
7 changes: 1 addition & 6 deletions packages/cli/cli-web/postcss.config.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1 @@
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
}
module.exports = require("@captain/tailwind-config/postcss");
3 changes: 3 additions & 0 deletions packages/cli/cli-web/src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
@tailwind utilities;

:root {
font-family: "Inter", -apple-system, "Segoe UI", "Roboto", "Oxygen", "Ubuntu",
"Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;

font-size: 16px;
line-height: 24px;
font-weight: 400;
Expand Down
4 changes: 1 addition & 3 deletions packages/cli/cli-web/tailwind.config.cjs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
presets: [require("@captain/tailwind-config")],
content: ["./index.html", "./src/**/*.{js,ts,jsx,tsx}"],
theme: {
extend: {},
},
plugins: [require("@tailwindcss/forms")],
};
11 changes: 11 additions & 0 deletions packages/config/tailwind/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ["./src/**/*.{ts,tsx}", "./src/_app.tsx"],
theme: {
fontFamily: {
display: ["Inter"],
},
extend: {},
},
plugins: [],
};
15 changes: 15 additions & 0 deletions packages/config/tailwind/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "@captain/tailwind-config",
"version": "0.1.0",
"main": "index.js",
"license": "MIT",
"files": [
"index.js",
"postcss.js"
],
"devDependencies": {
"autoprefixer": "^10.4.13",
"postcss": "^8.4.21",
"tailwindcss": "^3.2.4"
}
}
6 changes: 6 additions & 0 deletions packages/config/tailwind/postcss.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
};
1 change: 1 addition & 0 deletions packages/hosted/www/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"dependencies": {
"@captain/auth": "*",
"@captain/db": "*",
"@captain/tailwind-config": "*",
"@captain/trpc": "*",
"@formkit/auto-animate": "^1.0.0-beta.3",
"@headlessui/react": "^1.7.4",
Expand Down
7 changes: 1 addition & 6 deletions packages/hosted/www/postcss.config.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1 @@
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
};
module.exports = require("@captain/tailwind-config/postcss");
5 changes: 1 addition & 4 deletions packages/hosted/www/tailwind.config.cjs
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ["./src/**/*.{js,ts,jsx,tsx}"],
theme: {
extend: {},
},
presets: [require("@captain/tailwind-config")],
plugins: [require("@tailwindcss/forms")],
};
22 changes: 14 additions & 8 deletions packages/marketing/docs/static/img/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions packages/marketing/webhookthing-marketing/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"start": "next start"
},
"dependencies": {
"@captain/tailwind-config": "*",
"@tanstack/react-query": "^4.20.0",
"@trpc/client": "^10.8.1",
"@trpc/next": "^10.8.1",
Expand Down
7 changes: 1 addition & 6 deletions packages/marketing/webhookthing-marketing/postcss.config.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1 @@
module.exports = {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
};
module.exports = require("@captain/tailwind-config/postcss");
5 changes: 3 additions & 2 deletions packages/marketing/webhookthing-marketing/src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,9 @@ const Home: NextPage = () => {
"
>
<div className="container flex flex-col items-center justify-center gap-12 px-4 py-16 ">
<h1 className="text-[3.5rem] font-extrabold tracking-tight text-white sm:text-[5rem]">
webhook<span className="text-indigo-600">thing</span>
<h1 className="text-[3.5rem] font-medium tracking-tighter text-white sm:text-[5rem]">
webhook
<span className="font-extrabold text-indigo-600 ">thing</span>
</h1>
<div className="flex w-96 max-w-sm flex-col gap-4 rounded-xl bg-white/10 p-6 text-white">
{!submitted ? (
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

html,
body {
font-family: "Inter", -apple-system, "Segoe UI", "Roboto", "Oxygen", "Ubuntu",
"Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
8 changes: 2 additions & 6 deletions packages/marketing/webhookthing-marketing/tailwind.config.cjs
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
/** @type {import('tailwindcss').Config} */
/** @type {import("tailwindcss").Config} */
module.exports = {
content: ["./src/**/*.{js,ts,jsx,tsx}"],
theme: {
extend: {},
},
plugins: [],
presets: [require("@captain/tailwind-config")],
};
Loading

2 comments on commit 74db096

@vercel
Copy link

@vercel vercel bot commented on 74db096 Jan 28, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

captain-webhookthing-marketing – ./packages/marketing/webhookthing-marketing

captain-webhookthing-marketing-pinglabs.vercel.app
captain-webhookthing-marketing.vercel.app
captain-webhookthing-marketing-git-main-pinglabs.vercel.app
webhookthing.com
www.webhookthing.com

@vercel
Copy link

@vercel vercel bot commented on 74db096 Jan 28, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

captain-docs – ./packages/marketing/docs

captain-docs-t3dotgg-pinglabs.vercel.app
docs.webhookthing.com
captain-docs-pinglabs.vercel.app
captain-docs.vercel.app

Please sign in to comment.