Now instead of dark classes being applied based on{" "}
prefers-color-scheme, they will be applied whenever the
@@ -122,7 +137,6 @@ module.exports = {
Send
diff --git a/packages/documentation/src/Styles/QuickStart.stories.tsx b/packages/documentation/src/Styles/QuickStart.stories.tsx
index 1bbbf9c4..ac9a94e2 100644
--- a/packages/documentation/src/Styles/QuickStart.stories.tsx
+++ b/packages/documentation/src/Styles/QuickStart.stories.tsx
@@ -1,7 +1,14 @@
+/* eslint-disable @typescript-eslint/ban-ts-comment */
+
import { Story } from "@ladle/react";
+import { Highlight, Prism, themes } from "prism-react-renderer";
export default { title: "Styles" };
+(typeof global !== "undefined" ? global : window).Prism = Prism;
+// @ts-ignore
+await import("prismjs/components/prism-bash");
+
export const QuickStart: Story = () => (
Styles
@@ -17,18 +24,32 @@ export const QuickStart: Story = () => (
You have to install the @versini/ui-styles package which
provides our TailwindCSS plugin:
-
Finally, while our Typography styles could be used as is, some styles are
@@ -46,13 +79,25 @@ export default twPlugin.merge({
your project, simply copy the following lines in your index.html{" "}
head:
@@ -60,23 +105,36 @@ export default twPlugin.merge({
prose-lighter classes to add our typography styles to any
vanilla HTML:
-
-
- {`
+
Garlic bread with cheese: What the science tells us
- For years parents have espoused the health benefits of eating garlic bread with cheese to their
- children, with the food earning such an iconic status in our culture that kids will often dress
- up as warm, cheesy loaf for Halloween.
+ For years parents have espoused the health benefits of eating
+ garlic bread with cheese to their children, with the food
+ earning such an iconic status in our culture that kids will
+ often dress up as warm, cheesy loaf for Halloween.
- But a recent study shows that the celebrated appetizer may be linked to a series of rabies cases
- springing up around the country.
+ But a recent study shows that the celebrated appetizer may be
+ linked to a series of rabies cases springing up around the country.
NOTE: always include the prose class when
@@ -85,26 +143,40 @@ export default twPlugin.merge({
Dark mode
- Our typography styles are designed to work in dark mode, too. Just add the
- dark: prefix to the classes:
+ Our typography styles are designed to automatically work in dark mode,
+ too. Just add the dark: prefix to the classes:
-
-
- {`
+
Garlic bread with cheese: What the science tells us
- For years parents have espoused the health benefits of eating garlic bread with cheese to their
- children, with the food earning such an iconic status in our culture that kids will often dress
- up as warm, cheesy loaf for Halloween.
+ For years parents have espoused the health benefits of eating
+ garlic bread with cheese to their children, with the food
+ earning such an iconic status in our culture that kids will
+ often dress up as warm, cheesy loaf for Halloween.
- But a recent study shows that the celebrated appetizer may be linked to a series of rabies cases
- springing up around the country.
+ But a recent study shows that the celebrated appetizer may be
+ linked to a series of rabies cases springing up around the country.
By default, Tailwind removes all of the default browser styling from
paragraphs, headings, lists and more. This ends up being really useful
@@ -54,7 +69,9 @@ const CommonTemplate = ({
that you can slap on any block of vanilla HTML content and turn it into
a beautiful, well-formatted document:
-
{`
+
Garlic bread with cheese: What the science tells us
For years parents have espoused the health benefits of eating
@@ -64,11 +81,24 @@ const CommonTemplate = ({
But a recent study shows that the celebrated appetizer may be
- linked to a series of rabies cases springing up around the
- country.
+ linked to a series of rabies cases springing up around the country.
What follows from here is just a bunch of absolute nonsense I've written
@@ -101,17 +131,6 @@ const CommonTemplate = ({
like trash. Make it good then it won't be bad.
-
- It's probably important that images look okay here by default as well:
-
-
Now I'm going to show you an example of an unordered list to make sure
that looks good, too: