From e3f78877a02e836dcf3ce58da0a740fd15769d80 Mon Sep 17 00:00:00 2001 From: Binh Tran Date: Tue, 18 Jun 2024 16:43:09 +0700 Subject: [PATCH 1/4] build(deps): add daisyui --- packages/www/.prettierrc | 1 - packages/www/package.json | 1 + packages/www/tailwind.config.js | 5 +++-- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/www/.prettierrc b/packages/www/.prettierrc index 67d8327..8c79b5e 100644 --- a/packages/www/.prettierrc +++ b/packages/www/.prettierrc @@ -5,7 +5,6 @@ "printWidth": 100, "plugins": [ "prettier-plugin-svelte", - "prettier-plugin-tailwindcss", "prettier-plugin-tailwindcss" ], "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] diff --git a/packages/www/package.json b/packages/www/package.json index 0a208d2..7e729e7 100644 --- a/packages/www/package.json +++ b/packages/www/package.json @@ -22,6 +22,7 @@ "@sveltejs/vite-plugin-svelte": "^3.0.0", "@types/eslint": "^8.56.7", "autoprefixer": "^10.4.19", + "daisyui": "^4.12.2", "eslint": "^9.0.0", "eslint-config-prettier": "^9.1.0", "eslint-plugin-svelte": "^2.36.0", diff --git a/packages/www/tailwind.config.js b/packages/www/tailwind.config.js index 3ccf2aa..09122c1 100644 --- a/packages/www/tailwind.config.js +++ b/packages/www/tailwind.config.js @@ -1,4 +1,5 @@ -/** @type {import('tailwindcss').Config} */ +import daisyui from 'daisyui'; + /** @type {import('tailwindcss').Config} */ export default { content: ['./src/**/*.{html,js,svelte,ts}'], @@ -7,5 +8,5 @@ export default { extend: {} }, - plugins: [] + plugins: [daisyui] }; From c61a252349cd6f51909f6f7f4a83143724bd63ac Mon Sep 17 00:00:00 2001 From: Binh Tran Date: Wed, 19 Jun 2024 06:59:14 +0700 Subject: [PATCH 2/4] style(format): make consistent --- .editorconfig | 4 ++-- packages/www/.prettierrc | 5 +---- tsconfig.json | 27 --------------------------- 3 files changed, 3 insertions(+), 33 deletions(-) delete mode 100644 tsconfig.json diff --git a/.editorconfig b/.editorconfig index c8d1658..cfdee98 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,5 +1,5 @@ root = true -[*.{js,ts,css,html}] +[*.{js,ts,css,html,svelte,json}] indent_size = 2 -indent_style = space \ No newline at end of file +indent_style = tab \ No newline at end of file diff --git a/packages/www/.prettierrc b/packages/www/.prettierrc index 8c79b5e..8bc6e86 100644 --- a/packages/www/.prettierrc +++ b/packages/www/.prettierrc @@ -3,9 +3,6 @@ "singleQuote": true, "trailingComma": "none", "printWidth": 100, - "plugins": [ - "prettier-plugin-svelte", - "prettier-plugin-tailwindcss" - ], + "plugins": ["prettier-plugin-svelte", "prettier-plugin-tailwindcss"], "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] } diff --git a/tsconfig.json b/tsconfig.json deleted file mode 100644 index 238655f..0000000 --- a/tsconfig.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "compilerOptions": { - // Enable latest features - "lib": ["ESNext", "DOM"], - "target": "ESNext", - "module": "ESNext", - "moduleDetection": "force", - "jsx": "react-jsx", - "allowJs": true, - - // Bundler mode - "moduleResolution": "bundler", - "allowImportingTsExtensions": true, - "verbatimModuleSyntax": true, - "noEmit": true, - - // Best practices - "strict": true, - "skipLibCheck": true, - "noFallthroughCasesInSwitch": true, - - // Some stricter flags (disabled by default) - "noUnusedLocals": false, - "noUnusedParameters": false, - "noPropertyAccessFromIndexSignature": false - } -} From f5fc320cdf93f7b562b00d5d7642cc59f669ab13 Mon Sep 17 00:00:00 2001 From: Binh Tran Date: Wed, 19 Jun 2024 07:00:42 +0700 Subject: [PATCH 3/4] build(deps): add clsx --- packages/www/package.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/www/package.json b/packages/www/package.json index 7e729e7..427e91f 100644 --- a/packages/www/package.json +++ b/packages/www/package.json @@ -38,5 +38,8 @@ "vite": "^5.0.3", "vitest": "^1.2.0" }, - "type": "module" + "type": "module", + "dependencies": { + "clsx": "^2.1.1" + } } From 9b789febd3381dc2b5bd37c9520fbdd290040ddc Mon Sep 17 00:00:00 2001 From: Binh Tran Date: Wed, 19 Jun 2024 07:01:41 +0700 Subject: [PATCH 4/4] feat: enhance navbar --- packages/www/src/lib/components/Navbar.svelte | 75 +++++++++++++++++++ .../www/src/lib/components/Privacy.svelte | 34 +++++++++ packages/www/src/lib/icons/Close.svelte | 6 ++ packages/www/src/lib/icons/Github.svelte | 7 ++ packages/www/src/lib/icons/Menu.svelte | 3 + packages/www/src/lib/icons/Shield.svelte | 6 ++ packages/www/src/routes/+layout.svelte | 8 +- packages/www/src/routes/+page.svelte | 10 ++- 8 files changed, 142 insertions(+), 7 deletions(-) create mode 100644 packages/www/src/lib/components/Navbar.svelte create mode 100644 packages/www/src/lib/components/Privacy.svelte create mode 100644 packages/www/src/lib/icons/Close.svelte create mode 100644 packages/www/src/lib/icons/Github.svelte create mode 100644 packages/www/src/lib/icons/Menu.svelte create mode 100644 packages/www/src/lib/icons/Shield.svelte diff --git a/packages/www/src/lib/components/Navbar.svelte b/packages/www/src/lib/components/Navbar.svelte new file mode 100644 index 0000000..317ad6c --- /dev/null +++ b/packages/www/src/lib/components/Navbar.svelte @@ -0,0 +1,75 @@ + + + diff --git a/packages/www/src/lib/components/Privacy.svelte b/packages/www/src/lib/components/Privacy.svelte new file mode 100644 index 0000000..84c170d --- /dev/null +++ b/packages/www/src/lib/components/Privacy.svelte @@ -0,0 +1,34 @@ + + + + + + diff --git a/packages/www/src/lib/icons/Close.svelte b/packages/www/src/lib/icons/Close.svelte new file mode 100644 index 0000000..6189750 --- /dev/null +++ b/packages/www/src/lib/icons/Close.svelte @@ -0,0 +1,6 @@ + diff --git a/packages/www/src/lib/icons/Github.svelte b/packages/www/src/lib/icons/Github.svelte new file mode 100644 index 0000000..eac6b13 --- /dev/null +++ b/packages/www/src/lib/icons/Github.svelte @@ -0,0 +1,7 @@ + diff --git a/packages/www/src/lib/icons/Menu.svelte b/packages/www/src/lib/icons/Menu.svelte new file mode 100644 index 0000000..fbab098 --- /dev/null +++ b/packages/www/src/lib/icons/Menu.svelte @@ -0,0 +1,3 @@ + diff --git a/packages/www/src/lib/icons/Shield.svelte b/packages/www/src/lib/icons/Shield.svelte new file mode 100644 index 0000000..e58a50f --- /dev/null +++ b/packages/www/src/lib/icons/Shield.svelte @@ -0,0 +1,6 @@ + diff --git a/packages/www/src/routes/+layout.svelte b/packages/www/src/routes/+layout.svelte index d1d005c..d7a29da 100644 --- a/packages/www/src/routes/+layout.svelte +++ b/packages/www/src/routes/+layout.svelte @@ -2,8 +2,6 @@ import '../app.css'; - - - - - +
+ +
diff --git a/packages/www/src/routes/+page.svelte b/packages/www/src/routes/+page.svelte index 5982b0a..a0ad948 100644 --- a/packages/www/src/routes/+page.svelte +++ b/packages/www/src/routes/+page.svelte @@ -1,2 +1,8 @@ -

Welcome to SvelteKit

-

Visit kit.svelte.dev to read the documentation

+ + +
+ + TODO: Add body +