# Fart.css Fart.css is a CSS library of styles reusable across your ✨fart-tastic✨ frontends. ## Quick Start Include the following line in the `
` of your HTML file: ```html ``` ## Documentation ## Getting started To get started with Fart.css, include the following line in the `` of your HTML file: Copy code ```html ``` From there, you can use the classes and styles provided by the CSS library. ## Variables Fart.css makes use of [CSS variables](https://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Cascading_variables/Using_custom_properties), which you can reference using `var(--css-variable)` for colors: Colors are defined in the [root.css](root.css) file. Copy code ```css :root { --fart-primary: #7dd87f; --fart-dark-primary: #0f2a0f; --fart-darker-dark-primary: #0a1f0a; --fart-lighter-dark-primary: #004021; --fart-secondary: #db7093; --fart-highlight: rgba(74, 140, 86, 0.3); --fart-white: #ddd; --fart-off-white: #aaa; } ``` addEventListener("load", () => { const root = document.querySelector(":root"); const rootStyles = getComputedStyle(root); document.querySelectorAll(".preview-color").forEach( (el) => { const variableName = el.getAttribute( "data-var", ); if (!variableName) { return; } el.textContent = rootStyles.getPropertyValue( variableName, ).trim(); }, ); }); ## Fonts The [fonts.css](fonts.css) file imports [Overpass](https://fonts.google.com/specimen/Overpass) from Google Fonts. ## Keyframes Fart.css provides a set of keyframes for animations in the [keyframes.css](keyframes.css) file. ## Semantics Fart.css provides implicit styling for a set of common HTML elements in the [semantics.css](semantics.css) file. Body and HTML elements are styled with: Copy code ```css html, body { background-color: var(--fart-darker-dark-primary); color: var(--fart-white); font-family: sans-serif; margin: 0; } ``` Check out the available styles in the [semantics.css](semantics.css) file. ### Headings Headings `` are styled with a custom color and padding. > Example blockquote Copy code ```htmlExample blockquote``` ### Horizontal rule Use `
` or `.fart-hr` to create a horizontal rule. The rule is styled with `var(--fart-primary)`. * * * Copy code ```html
``` ### Tables Tables `` are styled with a custom color scheme, borders, and hover effects. Wrap tables in a `.fart-table-wrap` div for horizontal scrolling on mobile devices. Type Pros Cons Email Everyone knows email, easy to start Conversations are `1:1` and can't be shared, hard to keep track of Chat (Discord) `1:many` conversations encourage community and faster responses Requires a Discord account, old posts are washed away by new ones Forum (Discourse) Everything is public, Topics are easier to organize work around, Slower pace Functional nature isn't the best for casual community discussions Copy code ```html
``` ## Misc Fart.css provides miscellaneous styles in the [misc.css](misc.css) file. ### Buttons Buttons `.fart-button` have a rounded button style with a custom color and hover effect. [Example button](#buttons) #### Disabled Buttons Disabled buttons can be created using the `:disabled` pseudo-class for `
Type Pros Cons Everyone knows email, easy to start Conversations are 1:1and can't be shared, hard to keep track ofChat (Discord) 1:manyconversations encourage community and faster responsesRequires a Discord account, old posts are washed away by new ones Forum (Discourse) Everything is public, Topics are easier to organize work around, Slower pace Functional nature isn't the best for casual community discussions