From b1f73c9bd3b45a0879d1a4793f609a6c68ada7ad Mon Sep 17 00:00:00 2001 From: github-actions Date: Wed, 29 Jan 2025 13:35:36 +0000 Subject: [PATCH] Deployed 3d187d7 to dev with MkDocs 1.6.1 and mike 2.1.3 --- dev/getting_started/adding_js_and_css/index.html | 4 ++-- versions.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dev/getting_started/adding_js_and_css/index.html b/dev/getting_started/adding_js_and_css/index.html index 7579ddb5..6b18a7cc 100644 --- a/dev/getting_started/adding_js_and_css/index.html +++ b/dev/getting_started/adding_js_and_css/index.html @@ -97,7 +97,7 @@ a component is rendered on the page. This is not true for JS and CSS defined in `Media.js/css`, where the linked JS / CSS are rendered as is. --->

Your components may depend on third-party packages or styling, or other shared logic. To load these additional dependencies, you can use a nested Media class.

This Media class behaves similarly to Django's Media class, with a few differences:

  1. Our Media class accepts various formats for the JS and CSS files: either a single file, a list, or (CSS-only) a dictonary (see below).
  2. Individual JS / CSS files can be any of str, bytes, Path, SafeString, or a function.
  3. If you set Media.extend to a list, it should be a list of Component classes.

Learn more about using Media.

[project root]/components/calendar/calendar.py
from django_components import Component
+-->  

Your components may depend on third-party packages or styling, or other shared logic. To load these additional dependencies, you can use a nested Media class.

This Media class behaves similarly to Django's Media class, with a few differences:

  1. Our Media class accepts various formats for the JS and CSS files: either a single file, a list, or (CSS-only) a dictonary (see below).
  2. Individual JS / CSS files can be any of str, bytes, Path, SafeString, or a function.
  3. If you set Media.extend to a list, it should be a list of Component classes.

Learn more about using Media.

[project root]/components/calendar/calendar.py
from django_components import Component
 
 class Calendar(Component):
     template_file = "calendar.html"
@@ -170,4 +170,4 @@
     </script>
   </body>
 </html>
-

Now that we have a fully-defined component, next let's use it in a Django template ➡️.

\ No newline at end of file +

Now that we have a fully-defined component, next let's use it in a Django template ➡️.

\ No newline at end of file diff --git a/versions.json b/versions.json index 7fab7b8d..40632297 100644 --- a/versions.json +++ b/versions.json @@ -1,7 +1,7 @@ [ { "version": "dev", - "title": "dev (b69c6e6)", + "title": "dev (3d187d7)", "aliases": [] }, {