From 89993f305ab7b0f212440258e92c6146334a32a6 Mon Sep 17 00:00:00 2001 From: Josh Creek <8179928+jcreek@users.noreply.github.com> Date: Sun, 7 Apr 2024 19:19:08 +0100 Subject: [PATCH] fix(#16): Ensure DaisyUI styles apply to components It turns out that tailwind excludes styles it hasn't found in use, so it needs to be explicitly told where to find the component files. This also therefore fixes the styles in the SignUp component. --- src/lib/components/SignUp.svelte | 40 +++++++++++++++++++++++++------- src/routes/+page.svelte | 2 -- tailwind.config.js | 2 +- 3 files changed, 33 insertions(+), 11 deletions(-) diff --git a/src/lib/components/SignUp.svelte b/src/lib/components/SignUp.svelte index 5fe82b6..ef0446c 100644 --- a/src/lib/components/SignUp.svelte +++ b/src/lib/components/SignUp.svelte @@ -28,12 +28,36 @@ } - +
+ - - + + + +
diff --git a/src/routes/+page.svelte b/src/routes/+page.svelte index b17ade1..919de56 100644 --- a/src/routes/+page.svelte +++ b/src/routes/+page.svelte @@ -58,5 +58,3 @@ - -
This is a component styled with Tailwind CSS
diff --git a/tailwind.config.js b/tailwind.config.js index d088db0..a216401 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -1,6 +1,6 @@ /** @type {import('tailwindcss').Config} */ export default { - content: ['./src/routes/**/*.{svelte,js,ts}'], + content: ['./src/routes/**/*.{svelte,js,ts}', './src/lib/components/**/*.{svelte,js,ts}'], theme: { extend: {} },