Skip to content

Commit

Permalink
chore: add vars for prose markdown generation (#1217)
Browse files Browse the repository at this point in the history
### What does this PR do?

* Adds "prose" variable definitions in tailwind configuration for
  markdown rendering. Without this, the rendered markdown does not work
  in dark mode.
* See:
  containers/podman-desktop-extension-ai-lab#1340
  regarding a similar issue

### Screenshot / video of UI

<!-- If this PR is changing UI, please include
screenshots or screencasts showing the difference -->

### What issues does this PR fix or reference?

<!-- Include any related issues from Podman Desktop
repository (or from another issue tracker). -->

Closes #1122

### How to test this PR?

View example details in both dark and light mode

<!-- Please explain steps to reproduce -->

Signed-off-by: Charlie Drage <[email protected]>
  • Loading branch information
cdrage authored Jan 27, 2025
1 parent f967023 commit 20d6d7a
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions packages/frontend/tailwind.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,22 @@ module.exports = {
'5xl': '30px',
'6xl': '36px',
},
extend: {
typography: (theme) => ({
DEFAULT: {
css: {
color: 'var(--pd-details-body-text)',
'--tw-prose-body': 'var(--pd-details-body-text)',
'--tw-prose-bold': 'var(--pd-details-body-text)',
'--tw-prose-headings': 'var(--pd-details-body-text)',
'--tw-prose-quotes': 'var(--pd-details-body-text)',
'--tw-prose-hr': 'var(--pd-details-body-text)',
'--tw-prose-links': 'var(--pd-link)',
'--tw-prose-code': 'var(--pd-details-body-text)',
},
},
}),
},
colors: {
'charcoal': {
600: '#27272a',
Expand Down

0 comments on commit 20d6d7a

Please sign in to comment.