fix: code blocks rendering + consistent styling with ciphera-website /learn
- Convert MDX CodeBlock components to standard markdown code fences - Add rehype-mdx-code-props to pass filename meta to code components - Custom pre/code MDX components map fences to CodeBlock - Add brand color badges (product + category) matching /learn layout - Match prose styling: orange inline code, orange links, white strong - Remove brand color background glow (not in /learn)
This commit is contained in:
@@ -16,7 +16,8 @@ Add the Pulse script to your base template with a debug guard.
|
||||
|
||||
Use Django's template tags to only load the script when `DEBUG` is `False`.
|
||||
|
||||
<CodeBlock filename="templates/base.html">{`<!DOCTYPE html>
|
||||
```html filename="templates/base.html"
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
@@ -35,7 +36,8 @@ Use Django's template tags to only load the script when `DEBUG` is `False`.
|
||||
<body>
|
||||
{% block content %}{% endblock %}
|
||||
</body>
|
||||
</html>`}</CodeBlock>
|
||||
</html>
|
||||
```
|
||||
|
||||
Make sure to pass `debug` to the template context via `settings.DEBUG`, or use a context processor to make it available globally.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user