diff --git a/.eslintignore b/.eslintignore index 439fa03..b5517f1 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1,3 +1,4 @@ generate_translations.js webpack.config.js +tailwind.config.js src/api_tests diff --git a/joinlemmy-translations b/joinlemmy-translations index 1bc6986..ab6cef1 160000 --- a/joinlemmy-translations +++ b/joinlemmy-translations @@ -1 +1 @@ -Subproject commit 1bc69869fda7ee144ddfbc4d9fb29af3a0d4619e +Subproject commit ab6cef1e8445caac3d643fd1eb9917783f88c643 diff --git a/lemmy-docs b/lemmy-docs index 0dc13b4..46e7d37 160000 --- a/lemmy-docs +++ b/lemmy-docs @@ -1 +1 @@ -Subproject commit 0dc13b4ea11daaa07d964c17f7a622e3a222367a +Subproject commit 46e7d377c5e27418c89df28e6c620a7a3265b62f diff --git a/lemmy-js-client b/lemmy-js-client index 4553c74..406d1c1 160000 --- a/lemmy-js-client +++ b/lemmy-js-client @@ -1 +1 @@ -Subproject commit 4553c749cb0fb74d62fd156ebd119dc479693dfd +Subproject commit 406d1c187bd4bd13203cfd41ea1c8872e69aae3f diff --git a/lemmy-translations b/lemmy-translations index 5a9d446..839f109 160000 --- a/lemmy-translations +++ b/lemmy-translations @@ -1 +1 @@ -Subproject commit 5a9d44656e2658ab7cb2dbec3fd1bfaf57654533 +Subproject commit 839f1097d07ba9d730e31f58c892de491442e490 diff --git a/package.json b/package.json index 3683814..9fa6ca8 100644 --- a/package.json +++ b/package.json @@ -9,15 +9,15 @@ "clean": "yarn run rimraf dist", "crawl": "node crawl.mjs", "lint": "node generate_translations.mjs && tsc --noEmit && eslint --report-unused-disable-directives --ext .js,.ts,.tsx src && prettier --check \"src/**/*.{ts,tsx,js,css,scss}\"", - "prebuild:dev": "yarn clean && node generate_translations.mjs", - "prebuild:prod": "yarn clean && node generate_translations.mjs", + "prebuild:dev": "yarn clean && node generate_translations.mjs && yarn tailwind", + "prebuild:prod": "yarn clean && node generate_translations.mjs && yarn tailwind", + "tailwind": "tailwindcss -i ./src/style.css -o ./dist/styles/styles.css", "prepare": "husky install", - "start": "yarn build:dev --watch" + "start": "yarn build:dev --watch & yarn tailwind --watch" }, "repository": "https://github.com/LemmyNet/joinlemmy-site", "dependencies": { "@typescript-eslint/parser": "^5.60.1", - "chota": "^0.9.2", "express": "~4.18.2", "i18next": "^23.2.6", "inferno": "^8.2.1", @@ -48,11 +48,11 @@ "copy-webpack-plugin": "^11.0.0", "countries-list": "^2.6.1", "css-loader": "^6.8.1", + "daisyui": "^3.7.5", "eslint": "^8.43.0", "eslint-plugin-prettier": "^4.2.1", "husky": "^8.0.3", "lint-staged": "^13.2.3", - "mini-css-extract-plugin": "^2.7.6", "prettier": "^3.0.0", "rimraf": "^5.0.1", "run-node-webpack-plugin": "^1.3.0", @@ -60,6 +60,7 @@ "sass-loader": "^13.3.2", "sortpack": "^2.3.4", "style-loader": "^3.3.3", + "tailwindcss": "^3.3.3", "terser": "^5.18.2", "typescript": "^5.1.6", "webpack": "5.88.1", @@ -72,12 +73,7 @@ }, "engineStrict": true, "lint-staged": { - "*.{ts,tsx,js}": [ - "prettier --write", - "eslint --fix" - ], - "package.json": [ - "sortpack" - ] + "*.{ts,tsx,js}": ["prettier --write", "eslint --fix"], + "package.json": ["sortpack"] } } diff --git a/src/assets/css/main.css b/src/assets/css/main.css deleted file mode 100644 index 0fe89d5..0000000 --- a/src/assets/css/main.css +++ /dev/null @@ -1,67 +0,0 @@ -:root { - --font-family-sans: Inter, Helvetica, Roboto, sans-serif; - --grid-maxWidth: 108rem; - --grid-gutter: 4rem; - --color-success: #fafafa; - --bg-color: #222222; - --bg-secondary-color: #131316; - --font-color: #f5f5f5; - --color-grey: #ccc; - --color-darkGrey: #777; - --color-success: #222222; -} -.card { - webkit-box-shadow: unset; - box-shadow: unset; - border: 1px solid var(--color-darkGrey) !important; -} -.stylized { - font-family: "CaviarDreams", Fallback, sans-serif; - font-size: 4em; - font-weight: bold; - margin: 0; -} -.icon { - display: inline-block; - max-width: 1.5rem; - max-height: 1.5rem; - stroke-width: 0; - stroke: currentColor; - fill: currentColor; -} -p { - font: 1.2em/1.62 sans-serif; -} -.join-banner { - width: 100%; - height: 100px; - object-fit: scale-down; -} -.app-banner { - width: 100%; - height: 300px; - object-fit: scale-down; -} -.app-icon { - display: inline-block; - height: 30px; - width: 30px; - margin-right: 10px; -} -img { - max-width: unset; -} -.footer-name { - display: inline-block !important; - padding: 0px 6px 0px 6px !important; -} - -.gold { - border-color: #ffd700 !important; - color: #ffd700; -} - -.language-selector { - margin-top: 7px; - background-color: #333; -} diff --git a/src/server/index.tsx b/src/server/index.tsx index 016668b..471eb94 100644 --- a/src/server/index.tsx +++ b/src/server/index.tsx @@ -55,6 +55,9 @@ server.get("/*", async (req, res) => {
+ // TODO make these only work in debug mode + + ${helmet.title.toString()} ${helmet.meta.toString()} @@ -70,40 +73,6 @@ server.get("/*", async (req, res) => { - - - ${helmet.link.toString()} diff --git a/src/shared/components/app.tsx b/src/shared/components/app.tsx index e204059..78e2008 100644 --- a/src/shared/components/app.tsx +++ b/src/shared/components/app.tsx @@ -7,7 +7,6 @@ import { NoMatch } from "./no-match"; import { Symbols } from "./symbols"; import { Navbar } from "./navbar"; import { Footer } from "./footer"; -import "./styles.scss"; export class App extends Component+ Lemmy +
+); + +const LemmyDesc = () => ( +{i18n.t("lemmy_desc")}
+); + +const LemmyTitleBlock = () => ( +{this.joinServer()}
{this.runServer()}