You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is likely that your logos and favicons are hosted on Kinde, but you may also manage externally hosted assets. Here's how assets are referenced in your custom code.
11
+
It is likely that your logos and favicons are managed in Kinde, but you may also manage externally hosted assets like stylesheets, fonts, and images.
12
12
13
-
## Favicons
13
+
## Kinde hosted assets
14
14
15
-
The Kinde infrastructure package ships with helper methods for accessing these:
15
+
Within your custom code you can reference assets which have been uploaded within the Kinde admin area. The Kinde infrastructure package ships with helper methods for accessing these:
We know you will want to use assets like fonts and images stored outside of Kinde. Our strict CSP which we have for security, can make calling external sources somewhat trickier, but with good reason.
79
+
We know you will want to use assets like stylesheets, fonts and images. Kinde does not currently offer hosting for these static assets and you will need to host them yourself.
87
80
88
-
Your root domain as well as any subdomains of that domain are added to our CSP by default so to use your own assets and comply with Kinde’s CSP, the assets should be stored on servers that share the same domain as your custom domain.
81
+
Your root domain as well as any subdomains of that domain are added to our Content-Security-Policy (CSP) by default so to use your own assets and comply with Kinde’s CSP, the assets should be stored on servers that share the same domain as your custom domain.
89
82
90
-
For example, if you are using the custom domain [`auth.myapp.com`](http://auth.myapp.com) you could host fonts/images/css at [`https://assets.myapp.com`](https://assets.myapp.com) and they would be accessible in your code.
83
+
For example, if you are using the custom domain `auth.myapp.com` you could host your external fonts, images and CSS files at `assets.myapp.com` and they would be accessible in your code.
Copy file name to clipboardExpand all lines: src/content/docs/design/customize-with-code/styling-with-css.mdx
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,6 +18,12 @@ For example, you can:
18
18
- Set the primary button’s background color with `--kinde-button-primary-background-color`.
19
19
- Set the color of a form field’s invalid message with `--kinde-control-associated-text-invalid-message-color` (or use `--kinde-shared-color-invalid` for a more global approach).
20
20
21
+
## Hosting your CSS and other asset files
22
+
23
+
We know you will want to use assets like stylesheets, fonts and images. Kinde does not currently offer hosting for these static assets and you will need to host them yourself.
24
+
25
+
We recommend hosting them on servers that share the same domain as your custom domain. For example, if you are using the custom domain `auth.myapp.com` you could host your external fonts, images and CSS files at `assets.myapp.com` and they would be accessible in your code.
26
+
21
27
## Define settings in your CSS
22
28
23
29
Kinde settings are standard CSS custom properties, making them easy to integrate into your custom CSS. You can also map your own design tokens or custom properties to Kinde settings for added consistency.
0 commit comments