Skip to content

Commit

Permalink
add tailwind typography plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
maany committed Oct 31, 2024
1 parent 191dd35 commit 8e8afd0
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/components/conversation/message.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export const ConversationMessage = ({
<ReactMarkdown
remarkPlugins={[[remarkGfm, { singleTilde: false }]]}
rehypePlugins={[rehypeRaw]}
className="prose text-gray-900 mt-2 mb-2"
className="prose text-wrap text-gray-900 mt-2 mb-2"
components={{
code({ className, children, ...props }) {
const match = /language-(\w+)/.exec(className || "");
Expand Down
2 changes: 1 addition & 1 deletion lib/tailwind/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ const theme = {
};

// eslint-disable-next-line @typescript-eslint/no-explicit-any
const plugins: any = ["tailwindcss-animate"];
const plugins: any = ["tailwindcss-animate", "@tailwindcss/typography"];

export {
content as defaultContent,
Expand Down
45 changes: 45 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@
"@storybook/react-vite": "^8.0.8",
"@storybook/test": "^8.0.8",
"@storybook/theming": "^8.0.10",
"@tailwindcss/typography": "^0.5.15",
"@testing-library/jest-dom": "^6.3.0",
"@testing-library/react": "^14.1.2",
"@types/node": "^20.11.10",
Expand Down

0 comments on commit 8e8afd0

Please sign in to comment.